Reputation: 193
My test cases all are pass but still, I am getting build failure error
Tests run: 12, Failures: 0, Errors: 0, Skipped: 0
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-failsafe-plugin:2.18:integration-test (default) on project StoreTestUiAutomation: Execution default of goal org.apache.maven.plugins:maven-failsafe-plugin:2.18:integration-test failed: java.lang.RuntimeException: org.apache.maven.surefire.report.ReporterException: Unable to create file for report: C:\Users\Nageswar\Desktop\E-Florist\qa-ui-automation\target\failsafe-reports_ [email protected] _ Mine@123456 _ T11Z101A _ New Recipient _ 07470 _ Nageswar _ Rao _ 55 broad street _ 8187828580 _ Birthday _ Nageswar _ test message _ Visa _ 4111111111111111 _ 123 _ Jan _ 2022 _ Nageswar _ Pattipati _ 13 nevins rd _ Wayne _ New Jersey _ United States _ 07470 _ 8187828580 _.txt (The filename, directory name, or volume label syntax is incorrect) -> [Help 1] [ERROR]
this is my pom.xml
http://maven.apache.org/xsd/maven-4.0.0.xsd"> 4.0.0
<groupId>net.serenity-bdd.demos</groupId>
<artifactId>StoreTestUiAutomation</artifactId>
<version>0.0.1-SNAPSHOT</version>
<packaging>jar</packaging>
<name>StoreTest</name>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<serenity.version>1.2.4</serenity.version>
<serenity.maven.version>1.2.4</serenity.maven.version>
<serenity.cucumber.version>1.1.27</serenity.cucumber.version>
</properties>
<!-- Define the Bintray repos for convenience -->
<repositories>
<repository>
<id>serenity</id>
<name>bintray</name>
<url>http://dl.bintray.com/serenity/maven</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>serenity</id>
<name>bintray-plugins</name>
<url>http://dl.bintray.com/serenity/maven</url>
</pluginRepository>
</pluginRepositories>
<dependencies>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-core</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-junit</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-rest-assured</artifactId>
<version>${serenity.version}</version>
</dependency>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-cucumber</artifactId>
<version>${serenity.cucumber.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
<version>1.6.1</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.7</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-text</artifactId>
<version>1.3</version>
</dependency>
<!-- https://mvnrepository.com/artifact/org.assertj/assertj-core -->
<dependency>
<groupId>org.assertj</groupId>
<artifactId>assertj-core</artifactId>
<version>3.8.0</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.12</version>
</dependency>
<dependency>
<groupId>com.sikulix</groupId>
<artifactId>sikulixapi</artifactId>
<version>1.1.0</version>
</dependency>
<!-- https://mvnrepository.com/artifact/com.opencsv/opencsv -->
<dependency>
<groupId>com.opencsv</groupId>
<artifactId>opencsv</artifactId>
<version>3.2</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>1.4</version>
<executions>
<execution>
<id>enforce</id>
<configuration>
<rules>
<requireUpperBoundDeps />
</rules>
</configuration>
<goals>
<goal>enforce</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>2.19.1</version>
<configuration>
<testFailureIgnore>true</testFailureIgnore>
</configuration>
</plugin>
<plugin>
<artifactId>maven-failsafe-plugin</artifactId>
<version>2.18</version>
<configuration>
<parallel>classes</parallel>
<threadCount>1</threadCount>
<argLine>-Xmx2048m</argLine>
<forkCount>1</forkCount>
<!-- <systemPropertyVariables> <webdriver.driver>${webdriver.driver}</webdriver.driver>
</systemPropertyVariables> -->
<includes>
<include>**/cucumber/junit/**/*.java</include>
<include>**/cucumber/*.java</include>
</includes>
</configuration>
<executions>
<execution>
<goals>
<goal>integration-test</goal>
<goal>verify</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<classifier>exec</classifier>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.2</version>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
<plugin>
<groupId>net.serenity-bdd.maven.plugins</groupId>
<artifactId>serenity-maven-plugin</artifactId>
<version>${serenity.maven.version}</version>
<dependencies>
<dependency>
<groupId>net.serenity-bdd</groupId>
<artifactId>serenity-core</artifactId>
<version>${serenity.version}</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>serenity-reports</id>
<phase>post-integration-test</phase>
<goals>
<goal>aggregate</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
<profiles>
<profile>
<id>firefox</id>
<properties>
<webdriver.driver>firefox</webdriver.driver>
</properties>
</profile>
<profile>
<id>chrome</id>
<properties>
<webdriver.driver>chrome</webdriver.driver>
<webdriver.chrome.driver>chromedriver.exe</webdriver.chrome.driver>
</properties>
</profile>
<profile>
<id>phantomjs</id>
<properties>
<webdriver.driver>phantomjs</webdriver.driver>
</properties>
</profile>
</profiles>
please help me to fix this issue.
Upvotes: 1
Views: 1078
Reputation: 1571
Assuming you are using a windows operating system, the key message seems to be the following:
"The filename, directory name, or volume label syntax is incorrect.". See the following link, https://msdn.microsoft.com/en-us/library/ms832054.aspx, where the following explanation is given:
The system does not accept the keyboard combination Alt+0 through Alt+32 or the following characters: \\ \\ / [ ] : | < > + ; = . ? "
User Action:
Correct the file name or volume label and try the command again.
In fact, I see from your logs the following file name:
filename:
C:\Users\Nageswar\Desktop\E-Florist\qa-ui-automation\target\failsafe-reports_ [email protected] _ Mine@123456 _ T11Z101A _ New Recipient _ 07470 _ Nageswar _ Rao _ 55 broad street _ 8187828580 _ Birthday _ Nageswar _ test message _ Visa _ 4111111111111111 _ 123 _ Jan _ 2022 _ Nageswar _ Pattipati _ 13 nevins rd _ Wayne _ New Jersey _ United States _ 07470 _ 8187828580 _.txt
I have tried to create a file with that name on a windows box and from the command prompt it is not possible. I get an error like:
C:\Users\Nageswar\Desktop\E-Florist\qa-ui-automation\target>echo. 2>"failsafe-reports_ [email protected] _ Mine@123456 _ T11Z101A _ New Recipient _ 07470 _ Nageswar _ Rao _ 55 broad street _ 8187828580 _ Birthday _ Nageswar _ test message _ Visa _ 4111111111111111 _ 123 _ Jan _ 2022 _ Nageswar _ Pattipati _ 13 nevins rd _ Wayne _ New Jersey _ United States _ 07470 _ 8187828580 _.txt"
Impossibile trovare il percorso specificato.
If I try to do it from the windows explorer, it does not fail but the file name is automatically truncated to:
failsafe-reports_ [email protected] _ Mine@123456 _ T11Z101A _ New Recipient _ 07470 _ Nageswar _ Rao _ 55 broad street _ 8187828580 _ Birthday _ Nageswar _ test message _ Visa _ 4111111111111111 _ 123 _ Jan _ 2
Or, if I keep the extension:
failsafe-reports_ [email protected] _ Mine@123456 _ T11Z101A _ New Recipient _ 07470 _ Nageswar _ Rao _ 55 broad street _ 8187828580 _ Birthday _ Nageswar _ test message _ Visa _ 4111111111111111 _ 123 _ Jan.txt
So, I think the problem is that the file name is too long.
Hope this helps.
Upvotes: 0