Appium Java Cucumber test scenarios are not executing in the AWS Device Farm

0

Hi Team,

I'm currently trying to execute Appium automated test scenarios on AWS device farm. There are no errors in the log, but no test scenario executed. I have included the testng.xml file which refers to the TestRunner class.

[DEVICEFARM] Setting up your device. This usually takes 2-3 minutes.
[DEVICEFARM] ########### Start executing testspec ###########
 
 
[DEVICEFARM] ########### Entering phase install ###########
 
[DeviceFarm] export APPIUM_VERSION=1.14.2
[DeviceFarm] avm $APPIUM_VERSION
/usr/bin/avm: line 261: appium: command not found
      exists : 
[DeviceFarm] ln -s /usr/local/avm/versions/$APPIUM_VERSION/node_modules/.bin/appium  /usr/local/avm/versions/$APPIUM_VERSION/node_modules/appium/bin/appium.js
 
[DEVICEFARM] ########### Entering phase pre_test ###########
 
[DeviceFarm] export CLASSPATH=$CLASSPATH:$DEVICEFARM_TESTNG_JAR
[DeviceFarm] export CLASSPATH=$CLASSPATH:$DEVICEFARM_TEST_PACKAGE_PATH/*
[DeviceFarm] export CLASSPATH=$CLASSPATH:$DEVICEFARM_TEST_PACKAGE_PATH/dependency-jars/*
[DeviceFarm] echo "Start appium server"
Start appium server
[DeviceFarm] appium --log-timestamp --default-capabilities "{\"deviceName\": \"$DEVICEFARM_DEVICE_NAME\", \"platformName\":\"$DEVICEFARM_DEVICE_PLATFORM_NAME\", \"app\":\"$DEVICEFARM_APP_PATH\", \"udid\":\"$DEVICEFARM_DEVICE_UDID\", \"platformVersion\":\"$DEVICEFARM_DEVICE_OS_VERSION\", \"chromedriverExecutable\":\"$DEVICEFARM_CHROMEDRIVER_EXECUTABLE\"}" >> $DEVICEFARM_LOG_DIR/appiumlog.txt 2>&1 &
[DeviceFarm] start_appium_timeout=0; while [ true ]; do
    if [ $start_appium_timeout -gt 60 ];
    then
        echo "appium server never started in 60 seconds. Exiting";
        exit 1;
    fi;
    grep -i "Appium REST http interface listener started on 0.0.0.0:4723" $DEVICEFARM_LOG_DIR/appiumlog.txt >> /dev/null 2>&1;
    if [ $? -eq 0 ];
    then
        echo "Appium REST http interface listener started on 0.0.0.0:4723";
        break;
    else
        echo "Waiting for appium server to start. Sleeping for 1 second";
        sleep 1;
        start_appium_timeout=$((start_appium_timeout+1));
    fi;
done;
Waiting for appium server to start. Sleeping for 1 second
Waiting for appium server to start. Sleeping for 1 second
Waiting for appium server to start. Sleeping for 1 second
Waiting for appium server to start. Sleeping for 1 second
Appium REST http interface listener started on 0.0.0.0:4723
 
[DEVICEFARM] ########### Entering phase test ###########
 
[DeviceFarm] echo "Navigate to test package directory"
Navigate to test package directory
[DeviceFarm] cd $DEVICEFARM_TEST_PACKAGE_PATH
[DeviceFarm] echo "Start Appium JUnit test"
Start Appium JUnit test
[DeviceFarm] java -Dappium.screenshots.dir=$DEVICEFARM_SCREENSHOT_PATH org.testng.TestNG -junit -testjar *-tests.jar -d $DEVICEFARM_LOG_DIR/test-output
[TestNG] Running:
  /tmp/scratch5Hh0UX.scratch/test-packagezOobaa/testng.xml


===============================================
Regression
Total tests run: 0, Failures: 0, Skips: 0
===============================================

 
[DEVICEFARM] ########### Entering phase post_test ###########
 
 
[DEVICEFARM] ########### Finish executing testspec ###########
 
[DEVICEFARM] ########### Setting upload permissions ###########
 
 
[DEVICEFARM] Tearing down your device. Your tests report will come shortly.

https://us-west-2.console.aws.amazon.com/devicefarm/home?region=us-east-2#/mobile/projects/679dd7ea-c057-48a9-9fa6-cb581cf8133a/runs/716ddf89-b27a-4310-aecf-5eda2f2d7ac2/jobs/00000

Appreciate your help on this issue.

Regards, Wathsala.

asked 8 months ago29 views