Version 6.3.0 (Beta)

releases

#1

This is a companion discussion topic for the original entry at https://docs.katalon.com/katalon-studio/new/version-630.html

On UI Automation Can we perform record without installing the app everytime
#2

how to use start existing application


#3

Hi @395201116,

Please use this keyword:

Mobile.startExistingApplication('appId')

Thanks


#4

i have use it, the script like this

import static com.kms.katalon.core.checkpoint.CheckpointFactory.findCheckpoint

import static com.kms.katalon.core.testcase.TestCaseFactory.findTestCase
import static com.kms.katalon.core.testdata.TestDataFactory.findTestData
import static com.kms.katalon.core.testobject.ObjectRepository.findTestObject
import com.kms.katalon.core.checkpoint.Checkpoint as Checkpoint
import com.kms.katalon.core.cucumber.keyword.CucumberBuiltinKeywords as CucumberKW
import com.kms.katalon.core.mobile.keyword.MobileBuiltInKeywords as Mobile
import com.kms.katalon.core.model.FailureHandling as FailureHandling
import com.kms.katalon.core.testcase.TestCase as TestCase
import com.kms.katalon.core.testdata.TestData as TestData
import com.kms.katalon.core.testobject.TestObject as TestObject
import com.kms.katalon.core.webservice.keyword.WSBuiltInKeywords as WS
import com.kms.katalon.core.webui.keyword.WebUiBuiltInKeywords as WebUI
import internal.GlobalVariable as GlobalVariable

Mobile.startExistingApplication(‘cn.com.pconline.shopping’)

Mobile.tap(findTestObject('n/android.widget.TextView23 - '), 0)

Mobile.tap(findTestObject(‘n/android.widget.TextView7 - Hisense H55E3A 554K’), 0)

Mobile.tap(findTestObject(‘n/android.widget.ImageView0’), 0)

Mobile.closeApplication()


but have wrong in running,like this


Unable to start app with application ID: ‘cn.com.pconline.shopping’ (Root cause: groovy.lang.MissingMethodException: No signature of method: com.kms.katalon.core.appium.driver.SwipeableAndroidDriver.activateApp() is applicable for argument types: (java.lang.String) values: [cn.com.pconline.shopping]
at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword$_startApplication_closure1.doCall(StartExistingApplicationKeyword.groovy:41)
at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword$_startApplication_closure1.doCall(StartExistingApplicationKeyword.groovy)
at com.kms.katalon.core.mobile.keyword.internal.MobileKeywordMain.runKeyword(MobileKeywordMain.groovy:21)
at com.kms.katalon.core.mobile.keyword.internal.MobileKeywordMain$runKeyword.call(Unknown Source)
at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword.startApplication(StartExistingApplicationKeyword.groovy:43)
at com.kms.katalon.core.mobile.keyword.builtin.StartExistingApplicationKeyword.execute(StartExistingApplicationKeyword.groovy:34)
at com.kms.katalon.core.keyword.internal.KeywordExecutor.executeKeywordForPlatform(KeywordExecutor.groovy:56)
at com.kms.katalon.core.mobile.keyword.MobileBuiltInKeywords.startExistingApplication(MobileBuiltInKeywords.groovy:88)
at com.kms.katalon.core.mobile.keyword.MobileBuiltInKeywords$startExistingApplication.call(Unknown Source)
at New Test Case (1).run(New Test Case (1):16)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:114)
at com.kms.katalon.core.main.TestCaseMain.runTestCase(TestCaseMain.java:105)
at com.kms.katalon.core.main.TestCaseMain$runTestCase$0.call(Unknown Source)
at TempTestCase1562040377598.run(TempTestCase1562040377598.groovy:21)
)


#5

the script is create by record


#6

@395201116,

We will check this case. Thanks for your report.


#7

Hi @395201116,

Our QAs verified that Mobile.startExistingApplication is working normally. Please provide more information:

  • Appium version
  • Your OS version
  • The Katalon Studio zip file location/ URL you downloaded.

Thanks.


#8

appium version: 1.12.1

OS : window 7 service pack 1

package : https://github-production-release-asset-2e65be.s3.amazonaws.com/148249057/4916cc00-9805-11e9-9ab0-837ad225103d?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Credential=AKIAIWNJYAX4CSVEH53A%2F20190701%2Fus-east-1%2Fs3%2Faws4_request&X-Amz-Date=20190701T082053Z&X-Amz-Expires=300&X-Amz-Signature=0a5b458c7e45becb3e2f90c086973f1410bf317ce418c757a809951272e4673b&X-Amz-SignedHeaders=host&actor_id=0&response-content-disposition=attachment%3B%20filename%3DKatalon_Studio_Windows_64-6.3.0.zip&response-content-type=application%2Foctet-stream


#9

I don’t know if it’s because I’m upgrading by overwriting old versions of directory files


#10

Maybe, you should copy the fresh install to another folder first.

Thanks.


#11

I tried it, and now it’s OK

Now I can confirm that the issue was caused by the coverage upgrade

thanks!


#12

Hello,

I see couple of errors after execution on Release 6.3.0. These are just errors and not failures. All these cases are working fine on Release 6.2.0. Few logs below for reference…

==================================================================================
groovy.lang.GroovyRuntimeException: Failed to parse template script (your template may contain an error or be trying to use expressions not currently supported): startup failed:
GStringTemplateScript388.groovy: 2: illegal string body character after dollar sign;
solution: either escape a literal dollar sign “$5” or bracket the value expression “${5}” @ line 2, column 125.
ge/144531?$xsmall$’ and @cla
^

1 error

at com.kms.katalon.core.util.StrSubstitutor.replace(StrSubstitutor.java:37)
at com.kms.katalon.core.testobject.ObjectRepository.lambda$0(ObjectRepository.java:255)
at com.kms.katalon.core.testobject.ObjectRepository.findWebUIObject(ObjectRepository.java:252)
at com.kms.katalon.core.testobject.ObjectRepository.readTestObjectFile(ObjectRepository.java:206)
at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:174)
at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:127)
at com.kms.katalon.core.testobject.ObjectRepository$findTestObject.callStatic(Unknown Source)
at Add All to Wishlist - Guest.run(Add All to Wishlist - Guest:48)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)
at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)
at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestCaseMainPhase(TestSuiteExecutor.java:142)
at com.kms.katalon.core.main.TestSuiteExecutor.accessTestSuiteMainPhase(TestSuiteExecutor.java:118)
at com.kms.katalon.core.main.TestSuiteExecutor.execute(TestSuiteExecutor.java:85)
at com.kms.katalon.core.main.TestCaseMain.startTestSuite(TestCaseMain.java:157)
at com.kms.katalon.core.main.TestCaseMain$startTestSuite$0.call(Unknown Source)
at TempTestSuite1562194060967.run(TempTestSuite1562194060967.groovy:35)

=================================================================================
Test Cases/PDP - FAILED.

Reason:

groovy.lang.MissingPropertyException: No such property: data for class: groovy.lang.Binding

at com.kms.katalon.core.util.StrSubstitutor.replace(StrSubstitutor.java:37)

at com.kms.katalon.core.testobject.ObjectRepository.lambda$0(ObjectRepository.java:255)

at com.kms.katalon.core.testobject.ObjectRepository.findWebUIObject(ObjectRepository.java:252)

at com.kms.katalon.core.testobject.ObjectRepository.readTestObjectFile(ObjectRepository.java:206)

at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:174)

at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:127)

at com.kms.katalon.core.testobject.ObjectRepository$findTestObject.callStatic(Unknown Source)

at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)

at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)

at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)

at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)

at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:307)

at com.kms.katalon.core.main.TestCaseExecutor.accessMainPhase(TestCaseExecutor.java:299)

at com.kms.katalon.core.main.TestCaseExecutor.execute(TestCaseExecutor.java:233)

at com.kms.katalon.core.main.TestSuiteExecutor.accessTestCaseMainPhase(TestSuiteExecutor.java:142)

at com.kms.katalon.core.main.TestSuiteExecutor.accessTestSuiteMainPhase(TestSuiteExecutor.java:118)

at com.kms.katalon.core.main.TestSuiteExecutor.execute(TestSuiteExecutor.java:85)

at com.kms.katalon.core.main.TestCaseMain.startTestSuite(TestCaseMain.java:157)

at com.kms.katalon.core.main.TestCaseMain$startTestSuite$0.call(Unknown Source)

at TempTestSuite1562194060967.run(TempTestSuite1562194060967.groovy:35)

===============================================================================

groovy.lang.GroovyRuntimeException: Failed to parse template script (your template may contain an error or be trying to use expressions not currently supported): startup failed:
GStringTemplateScript164.groovy: 2: illegal string body character after dollar sign;
solution: either escape a literal dollar sign “$5” or bracket the value expression “${5}” @ line 2, column 42.
plate() { return { out -> out << “”"//la
^

1 error

at com.kms.katalon.core.util.StrSubstitutor.replace(StrSubstitutor.java:37)

=================================================================================

Reason:
org.codehaus.groovy.control.MultipleCompilationErrorsException: startup failed:
15: unable to resolve class com.katalon.plugin.keyword.waitforangular.WaitForAngularKeywords
@ line 15, column 1.
import com.katalon.plugin.keyword.waitforangular.WaitForAngularKeywords
^

1 error

at com.kms.katalon.core.main.ScriptEngine.getScript(ScriptEngine.java:199)
at com.kms.katalon.core.main.ScriptEngine.run(ScriptEngine.java:194)
at com.kms.katalon.core.main.ScriptEngine.runScriptAsRawText(ScriptEngine.java:119)
at com.kms.katalon.core.main.TestCaseExecutor.runScript(TestCaseExecutor.java:337)
at com.kms.katalon.core.main.TestCaseExecutor.doExecute(TestCaseExecutor.java:328)
at com.kms.katalon.core.main.TestCaseExecutor.processExecutionPhase(TestCaseExecutor.java:

=======================================================================

Reason:
groovy.lang.GroovyRuntimeException: Failed to parse template script (your template may contain an error or be trying to use expressions not currently supported): startup failed:
GStringTemplateScript23.groovy: 2: illegal string body character after dollar sign;
solution: either escape a literal dollar sign “$5” or bracket the value expression “${5}” @ line 2, column 248.
cialized_about-us?$hybris-nav$’]) = coun
^

1 error

at com.kms.katalon.core.util.StrSubstitutor.replace(StrSubstitutor.java:37)
at com.kms.katalon.core.testobject.ObjectRepository.lambda$0(ObjectRepository.java:255)
at com.kms.katalon.core.testobject.ObjectRepository.findWebUIObject(ObjectRepository.java:252)
at com.kms.katalon.core.testobject.ObjectRepository.readTestObjectFile(ObjectRepository.java:206)
at com.kms.katalon.core.testobject.ObjectRepository.findTestObject(ObjectRepository.java:

==================================================================================


#13

Hello,

Just noticed that the parameterization of a test object is not functional in Katalon Studio - 6.3.0.rc3-6eaf9894f.

The same code is functional in KS 6.2.0
image

Thank you,
Cornel


#14

Hello
After finished test suite collection run the result tab showing the result without id/suite name
Please see the screenshot below

Thank you


#15

I’m not able to use Mobile.startExistingApplication feature of the new Katalon v.6.3.0. I’ve tried the following:

  1. Spying on an installed application on an android device
  2. Recording on an installed application on an android device
  3. Running test case with Mobile.startExistingApplication(“package_name”)

And all of them ends in this step:
[35m[UiAutomator2]e[39m Server packages are not going to be (re)installed

I can neither record nor spy or run test cases. It always stuck here “Server packages are not going to be (re)installed”

Any help will be highly appreciated!

OS: Windows 10
Katalon ver: 6.3.0
node ver: 10.16.0
npm ver: 6.9.0
appium ver: 1.14.0
Device type: Physical
Device name: Huawei
Device model: nova 2i
Mobile OS: Android 8.0 Oreo

Let me know if you require any further information.
FYI I also have the Katalon v6.2.2 in the same folder. I don’t if this can be the root cause by any chance.


#16

Hi @Noor_Yeaser_Khan,

Please show us full of the execution log.

Btw, if you upgrade appium from v1.8.1 to v1.14.0. Please follow these manual instruction:

  • Manually remove io.appium.uiautomator2.server.test and appium.uiautomator2.server from your devices.
  • Manually delete folder C://<user_folder>/.katalon/tools/android_sdk and let Katalon download again.

Thanks


#17

Hello, I tried using Version 6.3. Everything is working fine. I really liked the dark theme and dynamic test objects feature. Just I am not able to use Plugins with this new version. I have installed and reload the plugins, still I do not see those while adding custom keywords.
@duyluong

Thanks,
Ankit


#18

Hi @duyluong

I’ve performed the tasks you’ve mentioned and now I’m stuck here whenever I try to do anything using the startExistingApplication feature:
The installation of ‘appium-uiautomator2-server-debug-androidTest.apk’ took 1.824s

Here is the execution log:
e[35m[Appium]e[39m Welcome to Appium v1.14.0
e[35m[Appium]e[39m Non-default server args:
e[35m[Appium]e[39m port: 49886
e[35m[Appium]e[39m loglevel: info
e[35m[Appium]e[39m chromeDriverPort: 49887
e[35m[Appium]e[39m tmpDir: C:\Users\nyk50\AppData\Local\Temp\Katalon\Appium\Temp1565023700125
e[35m[Appium]e[39m Appium REST http interface listener started on 0.0.0.0:49886
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/statuse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/status e[39me[32m200e[39m e[90m20 ms - 68e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mGETe[39m e[37m/wd/hub/statuse[39m
e[35m[HTTP]e[39m e[90m{}e[39m
e[35m[HTTP]e[39m e[37m<-- GET /wd/hub/status e[39me[32m200e[39m e[90m3 ms - 68e[39m
e[35m[HTTP]e[39m e[90me[39m
e[35m[HTTP]e[39m e[37m–>e[39m e[37mPOSTe[39m e[37m/wd/hub/sessione[39m
e[35m[HTTP]e[39m e[90m{“desiredCapabilities”:{“appActivity”:".Settings",“appPackage”:“com.android.settings”,“newCommandTimeout”:1800,“platformVersion”:“8.0.0”,“automationName”:“uiautomator2”,“autoGrantPermissions”:true,“platformName”:“Android”,“udid”:“8UEDU18112007974”,“deviceName”:“HUAWEI RNE-L22 (Android 8.0.0)”,“platform”:“ANDROID”,“systemPort”:8214},“capabilities”:{“firstMatch”:[{“appium:appActivity”:".Settings",“appium:appPackage”:“com.android.settings”,“appium:autoGrantPermissions”:true,“appium:automationName”:“uiautomator2”,“appium:deviceName”:“HUAWEI RNE-L22 (Android 8.0.0)”,“appium:newCommandTimeout”:1800,“platform”:“ANDROID”,“platformName”:“android”,“appium:platformVersion”:“8.0.0”,“appium:systemPort”:8214,“appium:udid”:“8UEDU18112007974”}]}}e[39m
e[35m[BaseDriver]e[39m The capabilities [“platform”] are not standard capabilities and should have an extension prefix
e[35m[Appium]e[39m Appium v1.14.0 creating new AndroidUiautomator2Driver (v1.33.1) session
e[35m[Appium]e[39m Capabilities:
e[35m[Appium]e[39m platform: ANDROID
e[35m[Appium]e[39m platformName: android
e[35m[Appium]e[39m appActivity: .Settings
e[35m[Appium]e[39m appPackage: com.android.settings
e[35m[Appium]e[39m autoGrantPermissions: true
e[35m[Appium]e[39m automationName: uiautomator2
e[35m[Appium]e[39m deviceName: HUAWEI RNE-L22 (Android 8.0.0)
e[35m[Appium]e[39m newCommandTimeout: 1800
e[35m[Appium]e[39m platformVersion: 8.0.0
e[35m[Appium]e[39m systemPort: 8214
e[35m[Appium]e[39m udid: 8UEDU18112007974
e[35m[BaseDriver]e[39m The following capabilities were provided, but are not recognized by Appium:
e[35m[BaseDriver]e[39m platform
e[35m[BaseDriver]e[39m Session created with session id: b5fa128f-31d7-4b1c-a66f-c0c77ca3e0d1
e[35m[ADB]e[39m Found 1 ‘build-tools’ folders under ‘C:\Users\nyk50.katalon\tools\android_sdk’ (newest first):
e[35m[ADB]e[39m C:/Users/nyk50/.katalon/tools/android_sdk/build-tools/29.0.1
e[35m[ADB]e[39m Using ‘adb.exe’ from ‘C:\Users\nyk50.katalon\tools\android_sdk\platform-tools\adb.exe’
e[35m[AndroidDriver]e[39m Retrieving device list
e[35m[AndroidDriver]e[39m Using device: 8UEDU18112007974
e[35m[ADB]e[39m Using ‘adb.exe’ from ‘C:\Users\nyk50.katalon\tools\android_sdk\platform-tools\adb.exe’
e[35m[AndroidDriver]e[39m No app sent in, not parsing package/activity
e[35m[ADB]e[39m Using ‘aapt.exe’ from ‘C:\Users\nyk50.katalon\tools\android_sdk\build-tools\29.0.1\aapt.exe’
e[35m[ADB]e[39m Using ‘apksigner.bat’ from ‘C:\Users\nyk50.katalon\tools\android_sdk\build-tools\29.0.1\apksigner.bat’
e[35m[UiAutomator2]e[39m Server packages are going to be (re)installed
e[35m[ADB]e[39m The application at ‘C:\Users\nyk50\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-v3.7.0.apk’ is already cached to ‘/data/local/tmp/appium_cache/fe3aa6662b6c999cf661d7626a50da395fd786f4.apk’
e[35m[ADB]e[39m The installation of ‘appium-uiautomator2-server-v3.7.0.apk’ took 5.451s
e[35m[ADB]e[39m The application at ‘C:\Users\nyk50\AppData\Roaming\npm\node_modules\appium\node_modules\appium-uiautomator2-server\apks\appium-uiautomator2-server-debug-androidTest.apk’ is already cached to ‘/data/local/tmp/appium_cache/803351851ae3c5e95b3b134df12ac4dc20f5da62.apk’
e[35m[ADB]e[39m The installation of ‘appium-uiautomator2-server-debug-androidTest.apk’ took 1.824s

Please reach out to me if you have any further queries in order to debug this issue.

Thanks for your prompt response! :bowing_man:


#19

Hi @Noor_Yeaser_Khan,

You may try to add: appWaitActivity: * property in Project Settings/Desired Capabilities/Mobile/Android and try to run again.

If KS could not start the app, please show us more message. The Appium log above was not the full exception log.

Thanks


#20

Hi @duyluong, I highly appreciate your cooperation. As per your instruction, I’ve added appWaitActivity: * property in Project Settings/Desired Capabilities/Mobile/Android and tried to run again. Unfortunately, I didn’t had any better luck even this time. KS is not throwing any exception, it’s just stuck at:
The installation of ‘appium-uiautomator2-server-debug-androidTest.apk’ took 2.045s

Besides the above Appium log, I don’t have much in my hand as of now. If you can kindly instruct me any further on how to fetch additional logs that might help in debugging would be appreciated.

Thanks & Regards,
Noor Yeaser Khan