Android: Adding a custom test to the compatibility test suite - cts

I have created a simple test case using android studio that just checks whether the Device has WiFi Adapter or not and if it has then is it functioning or not. The test case is working fine on Android Studio but i don't have any idea how add that case to Android CTS and run it. I have configured git, downloaded the latest android source code for Android M.
Thanks in Advance !! :)

Related

problems using the Android Studio emulator with Flutter

when i try to emulate my flutter project i get this message, does anyone know what to do? When emulating in Android Studio some project with Kotlin works perfectly
Hey you should check buildToolsVersion "29.0.3". The version might be different but there would be buildToolsVersion, note down the version and check if it is installed or update/upgrade it from file > Project Structure

Flutter - Can't install apk on android

I'm new to flutter and on a phone I have it works and the app runs fine, but I sent the apk to another device and it couldn't be installed, I don't know if it's because of a plugin I'm using that is "speech to speech", since in that plugin I changed the version of min sdk to 21 but the android that I try to install has an android version of 10 that is higher, it seems to me, what would be the cause?
Remember Android no longer accept the app which has not been signed as release,. make sure you are making you are signing the app correctly, Android studio will help you.
The build flavor should be release, and the signature must be created before. But the easiest way is to run the app in profile mode,
flutter run --profile
Profile mode run as release mode but doesn't require to be manually signed.
There could be other reasons but do you know that the Flutter app cannot be installed on x86 Android
Flutter does not currently support building for x86 Android

Running Flutter on a Genymotion machine using VS Code

I'm using VS Code as my IDE for Flutter and I'm trying to run my app in a Genymotion machine. How can I do that? The machine doesn't appear in VS Code bottom bar in the Devices section.
N.B:
I'm not looking for any solutions regarding Android emulators or Android Studio, only VS Code with Genymotion.
Alright, so after an hour or so of searching I found out the solution. It's entirely the same as the approach of using Genymotion in Android Studio. The only difference is you don't need to install a plugin for VS Code. However, in my case, it was a bug in Genymotion it self. I was using v3.0.1 which had some incompatibility bug with Android SDK 28 and this was the reason why the Genymotion machine did not show up as a device in VS Code, because this latter relies on Android SDK to determine what are the devices that run Android.
The solution for me was simply upgrading my Genymotion to v3.0.2 which fixed the incompatibility with Android SDK 28.
In case anyone runs into this problem in the future and this doesn't work, make sure that your Genymotion ADB settings use the Android SDK installed in your machine by Android Studio and not the one shipped with Genymotion itself.

Launch/Test VS Emulator for Android in/from VS Code

I've noticed that Visual Studio has a separate/independent VS Emulator for Android, but I can't figure out how to launch/test their emulator directly from Visual Studio Code. Has anyone used it before? Can anyone tell me how to connect/launch the emulator in/from VS Code?
there is a marketplace plugin for that:
https://marketplace.visualstudio.com/items?itemName=343max.android-emulator-launcher
launch via
Cmd-Shit-P > Launch Android Emulator
you can also create a task to do it:
https://gist.github.com/wbroek/a2caf1ace90eac0c5e25497548f41a6e
and put the task in your debug pipeline (see this: https://www.gamedev.net/articles/programming/general-and-gameplay-programming/android-debugging-with-visual-studio-code-r4820/). this will launch the emulator. to have the emulator open to whatever you're doing, it depends on the framework, etc. For instance, React Native you can use expo for "realtime" updating/debugging (basically just an app that lives on the phone and proxies the compiled code). For full "automated" pipeline, you'd need a task to build your apk, upload it to the phone, then launch apk.

Appium with Android Studio

Does Appium with android studio needs uiautomator Viewer, Because Why i'm asking Here as a beginner I need To Know Appium Installation having Two Methods "Eclipse with appium" And Advanced Method is Appium with Android Studio. UIAUTOMATOR need or Not. for Appium with Android Studio.
Thanks in advance
I am not entirely sure of what you are asking, but if I understand correctly here is my answer:
I use Eclipse and Appium, and because the Android SDK plug-in for Eclipse has been deprecated, you need to install Android Studio to get the SDK. You also need to install the Android Studio to get the UIAutomator, which you will find you absolutely need to have. Once I installed the Android Studio, I've not had any need to actually use it as a development environment at all. The UIAutomator can be invoked from a command line.
it don't ned the uiautomator, you can use the inspector. so no need uiautomator if you want to set up the appium with the android studio.
if you are not using android studio then it needs it.
Depending the element which you need to access while running the test case.
If you can not get elements then its necessary to find element by xpath
Its available in android-sdk/tools/bin.
it's necessary to download android studio for appium as SDK plugin no longer available.
so don't worry just set all path correctly.
i'm new too but with help of android studio i'm not receiving any error or problem related UIAutomator.