mvn test

Topic created · 3 Posts · 133 Visualizações
  • Olá pessoal!

    Sou novo com appium e java e gostaria de rodar os meus testes por linha de comando, algo que atualmente faço com uma classe runner no eclipse.

    porém ao rodar o comando “mvn test” os testes não inciam, ele me retorna o seguinte log:mvn test
    [INFO] Scanning for projects…
    [INFO]
    [INFO] -------------< com.autosaving.ios:AutoSavingAutomationIos >-------------
    [INFO] Building AutoSavingAutomationIos 0.0.1-SNAPSHOT
    [INFO] --------------------------------[ jar ]---------------------------------
    [INFO]
    [INFO] — maven-resources-plugin:2.6:resources (default-resources) @ AutoSavingAutomationIos —
    [WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
    [INFO] Copying 0 resource
    [INFO]
    [INFO] — maven-compiler-plugin:3.1:compile (default-compile) @ AutoSavingAutomationIos —
    [INFO] Changes detected - recompiling the module!
    [WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
    [INFO] Compiling 8 source files to /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/target/classes
    [WARNING] error reading /Users/tbs/.m2/repository/net/java/dev/jna/jna/4.1.0/jna-4.1.0.jar; invalid LOC header (bad signature)
    [WARNING] /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/main/java/pages/ValueToAchieveScreen.java: /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/main/java/pages/ValueToAchieveScreen.java uses or overrides a deprecated API.
    [WARNING] /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/main/java/pages/ValueToAchieveScreen.java: Recompile with -Xlint:deprecation for details.
    [INFO]
    [INFO] — maven-resources-plugin:2.6:testResources (default-testResources) @ AutoSavingAutomationIos —
    [WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
    [INFO] Copying 0 resource
    [INFO]
    [INFO] — maven-compiler-plugin:3.1:testCompile (default-testCompile) @ AutoSavingAutomationIos —
    [INFO] Changes detected - recompiling the module!
    [WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
    [INFO] Compiling 7 source files to /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/target/test-classes
    [WARNING] error reading /Users/tbs/.m2/repository/net/java/dev/jna/jna/4.1.0/jna-4.1.0.jar; invalid LOC header (bad signature)
    [WARNING] /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/test/java/stepsDefinitions/TotalAmountValueSteps.java: /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/test/java/stepsDefinitions/TotalAmountValueSteps.java uses or overrides a deprecated API.
    [WARNING] /Users/tbs/Documents/Projetos/Globile/auto-saving-qa-ios/src/test/java/stepsDefinitions/TotalAmountValueSteps.java: Recompile with -Xlint:deprecation for details.
    [INFO]
    [INFO] — maven-surefire-plugin:2.12.4:test (default-test) @ AutoSavingAutomationIos —
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD SUCCESS
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 3.210 s
    [INFO] Finished at: 2019-05-28T14:20:18-03:00
    [INFO] ------------------------------------------------------------------------

    este é o meu pom:
    <project xmlns=“http://maven.apache.org/POM/4.0.0” xmlns:xsi=“http://www.w3.org/2001/XMLSchema-instance” xsi:schemaLocation=“http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd”>
    <modelVersion>4.0.0</modelVersion>
    <groupId>com.autosaving.ios</groupId>
    <artifactId>AutoSavingAutomationIos</artifactId>
    <version>0.0.1-SNAPSHOT</version>

    <dependencies>
    	<dependency>
    		<groupId>io.appium</groupId>
    		<artifactId>java-client</artifactId>
    		<version>4.1.2</version>
    	</dependency>
    	<dependency>
    		<groupId>info.cukes</groupId>
    		<artifactId>cucumber-java</artifactId>
    		<version>1.2.5</version>
    	</dependency>
    	<dependency>
    		<groupId>info.cukes</groupId>
    		<artifactId>cucumber-junit</artifactId>
    		<version>1.2.5</version>
    	</dependency>
    	<dependency>
    		<groupId>junit</groupId>
    		<artifactId>junit</artifactId>
    		<version>4.12</version>
    	</dependency>
    

    </dependencies>
    </project>

    Alguém poderia ajudar? 🙂

  • @Tico
    Valeu mano!