Skip to content
QiTASC.com / Troubleshooting /
Apptest and Selendroid Errors
/ .. /
Apptest and Selendroid Errors





Apptest Troubleshooting

Missing Tools

If aapt, jarsigner and keystore are not on the machine that is running intaQt, Apptests will not work. This can be resolved by launching intaQt using the QiTASC Cockpit, which will provide this software and set the correct ANDROID_HOME AND JAVA_HOME paths.

If this does not solve the problem or the QiTASC Cockpit is not being used on the machine running intaQt, then aapt jarsigner and keystore must all be installed:

  • aapt is a part of Android SDK built-tools and needs to be in the system path.

  • jarsigner is part of JDK and needs to be in the system path.

  • keystore is part of JDK and needs to be in the system path.

If keystore is not present, it can be generated manually from the command line:

1
keytool -genkey -v -keystore debug.keystore -alias androiddebugkey -keyalg RSA -keysize 2048 -validity 10000

When prompted for passwords, enter android.

Selendroid Issues

Most Selendroid-related issues occur in the open app step, where the app doesn't start. In the intaQt log, an error message such as Selendroid server on the device didn't come up after 20sec may appear.

The problem is usually related to having multiple versions of Selendroid or an outdated version. To solve the problem: 1. Check whether an older version of the app is installed on the phone. If so, delete the app and restart the test case. 2. See if two (or more) Selendroid apps are installed. In this case, delete all the Selendroid apps and restart the test case.

Selendroid Old Android Package Kit Issue

If using an old APK version in conjunction with an old Selendroid instrumentation on the phone, the signatures will not match with the current ones.

Error Message

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
java.lang.SecurityException: Permission Denial: starting instrumentation
ComponentInfo{io.selendroid.vodafone.onenet.android.mobile/io.selendroid.server.ServerInstrumentation}
from pid=5274, uid=5274 not allowed because package
io.selendroid.vodafone.onenet.android.mobile
does not have a signature matching the target vodafone.onenet.android.mobile

 at android.os.Parcel.readException(Parcel.java:1465)
 at android.os.Parcel.readException(Parcel.java:1419)
 at android.app.ActivityManagerProxy.startInstrumentation(ActivityManagerNative.java:3188)
 at com.android.commands.am.Am.runInstrument(Am.java:864)
 at com.android.commands.am.Am.onRun(Am.java:282)
 at com.android.internal.os.BaseCommand.run(BaseCommand.java:47)
 at com.android.commands.am.Am.main(Am.java:76)
 at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
 at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:243)
 at dalvik.system.NativeStart.main(Native Method)

Solution Remove Selendroid and intaQt apps, either through the Apps UI in Android or by using shell command and reinstalling the APK Data.

Note: Using the command adb shell pm list packages [options] <FILTER> will list all packages, optionally only those whose package name contains the text in <FILTER>.

INSTALL_PARSE_FAILED_NO_CERTIFICATES

Executing the open app command could lead to an INSTALL_PARSE_FAILED_NO_CERTIFICATES error message:

Open App Command

1
"And open app <appName> on <deviceId>"
Error Message
1
Failure [INSTALL_PARSE_FAILED_NO_CERTIFICATES]

In this case, remove the signature files from the APK. This can be done by executing the following command on the command line:

1
zip -d base.apk 'META-INF/.SF' 'META-INF/.RSA' 'META-INF/*SF'

NullPointerException

If a NullPointerException is followed by a line containing unlockScreen in intaQt's standard output then this is due to and unsupported version of Android.

Example

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
an 17, 2017 3:59:32 PM io.selendroid.standalone.server.model.SelendroidStandaloneDriver createNewTestSession
SEVERE: Error occurred while starting Selendroid session
java.lang.NullPointerException
    at io.selendroid.standalone.android.impl.DefaultHardwareDevice.unlockScreen(DefaultHardwareDevice.java:111)
    at io.selendroid.standalone.server.model.SelendroidStandaloneDriver.createNewTestSession(SelendroidStandaloneDriver.java:234)
    at io.selendroid.standalone.server.model.SelendroidStandaloneDriver.createNewTestSession(SelendroidStandaloneDriver.java:214)
    at io.selendroid.standalone.server.handler.CreateSessionHandler.handleRequest(CreateSessionHandler.java:40)
    at io.selendroid.standalone.server.BaseSelendroidStandaloneHandler.handle(BaseSelendroidStandaloneHandler.java:45)
    at io.selendroid.standalone.server.SelendroidServlet.handleRequest(SelendroidServlet.java:131)
    at io.selendroid.server.common.BaseServlet.handleHttpRequest(BaseServlet.java:67)
    at io.selendroid.server.common.http.ServerHandler.channelRead(ServerHandler.java:53)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
    at io.netty.handler.traffic.AbstractTrafficShapingHandler.channelRead(AbstractTrafficShapingHandler.java:223)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
    at io.netty.handler.codec.MessageToMessageDecoder.channelRead(MessageToMessageDecoder.java:103)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
    at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:163)
    at io.netty.channel.CombinedChannelDuplexHandler.channelRead(CombinedChannelDuplexHandler.java:148)
    at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:333)
    at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:319)
    at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:787)
    at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:125)
    at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:511)
    at io.netty.channel.nio.NioEventLoop.processS

This is because Selendroid currently only works with an Android API level equal to or less than Android 23 (Version 6). Android API levels 24 (version 7) and above are currently unsupported.