Reputation: 21
When i deploy the zip containing my appium scripts and test.jar (containing all dependency jars used in script) on aws device from run configuration it shows below error-
"could not found test.jar".
Any suggestion what i am missing.
Upvotes: 2
Views: 819
Reputation: 3374
If you take a look at step 6 in the instructions, you'll see an example of the expected package structure.
Build, package, and verify. For example:
$ mvn clean package –-DskipTests=true
$ tree target
.
|— acme-android-appium-1.0-SNAPSHOT.jar (this is the JAR containing everything built from the ./src/main directory)
|— acme-android-appium-1.0-SNAPSHOT-tests.jar (this is the JAR containing everything built from the ./src/test directory)
|— zip-with-dependencies.zip (this .zip file contains all of the items)
`— dependency-jars (this is the directory that contains all of your dependencies, built as JAR files)
|— com.some-dependency.bar-4.1.jar
|— com.another-dependency.thing-1.0.jar
|— joda-time-2.7.jar
|— log4j-1.2.14.jar
|— (and so on...)
The two key areas to look at here are:
Device Farm expects the uploaded package to contain JAR files built from both your ./src/main
and ./src/test
directories. Based on the error message, it is unable to find a *-tests.jar
file inside of your uploaded package.
My questions for you would be:
./src/main
and ./src/test
directory structure? Or are you using something different?mvn clean package --DskipTests=true && tree target
? This should give a clear understanding exactly of what files are missing.Upvotes: 1
Reputation: 101
Are you following the steps like http://docs.aws.amazon.com/devicefarm/latest/developerguide/test-types-android-appium-java-junit.html to create your zip file?
If no, what's the file/folder structure in your zip file?
If yes, could you please mail/PM the url for your failed test run? Then we could take a close look.
Upvotes: 0