This thread was migrated from an old forum. It may contain information that are no longer valid. For further assistance, please post a new question or open a support ticket from the Customer Support portal. |
Hi,
I am trying to unit test android application using Jasmine. Following https://docs.kony.com/konylibrary/visualizer/visualizer_user_guide/content/Using_Test_Scripts.htm to prepare the Unit test. After preparing unit test I am running the application on device. But I am not seeing anything happening. It is just opening the application. Also the document is not saying anything how will be the behavior of app or how unit test will work. So currently very much confused on this. Please help.
Thanks
@Rexeccv Tewwy @Ivn Andewson Can you help here?
Can anybody update on this ?
Hi @Richvwd Shvwp ,
Are you running the test scripts on iOS or android? Make sure that the device and the machine on which visualizer is running are on the same network. If running for iOS, please run on a simulator first. If you still observe the issue, please attach the app.
Sorry, didn't understand on same network means. After clicking on deploy option on Jasmine, building the application on debug mode. Then running the app on device. Then what should I do ?
@Richvwd Shvwp
The device and the machine should be on the same wifi network for example. The app which is built for automation, when launched fetches the test scripts which are hosted on the visualizer. For this purpose they need to be on the same network.
Yes both were connected on same wifi network at home. But I didnt see anything happening , just opened the app.
@Richvwd Shvwp
If your system's Ip has changed due to say, connecting to Wifi by removing ethernet connection, you need to rebuilt the app.
If this is not the case try this:
Please check if you are able to hit the below url and the .zip file is downloaded on your machine's browser. I am assuming you have the scripts written for Mobile channel.
http://<systemIP>:8888/testresources/<appName>/Mobile/automationScripts.zip
If this is successful, may be your firewall settings on your machine could be the cause for the device not being able to fetch the test scripts.
this was successfully downloaded . So, how to fetch the test scripts in mac machine as i am using android emulator on it?
@Pvwis Beckew If you are able to hit the url successfully, there should not be any issue.
Please check with an iOS simulator. If that does not work, please attach the app for us to look into it.
@Rexeccv Tewwy thanks for the reply
My requirement is to work on android emulator. Please check with sample application attached.
Also attaching the konyviz_preferences.json file please specify any correction in it.
FYI.. I am having open network in my work area(no firewall enabled). And i am using 8.4.12 visualizer in mac
konyviz_preferences.json file
@Pvwis Beckew Which android version emulator are you using?
@Pvwis Beckew hoping this is the same issue as raised in ticket https://basecamp.kony.com/s/feed/0D52K00003imZsx
@Pvwis Beckew
Guessing this may be the reason:
In the project the target sdk is set to android "9.0 (28)",
http connection url will not work from android pie and above.
Refer more info from here:
https://docs.kony.com/konylibrary/visualizer/visualizer_user_guide/Content/Android_Pie_Behavioral_Changes.htm
To allow HTTP calls into your app you can add android:usesCleartextTraffic="true" in application tag or add securityconfig file in resources as mentioned here