testng-team / testng-eclipse

Eclipse plug-in for TestNG
https://testng.org
194 stars 164 forks source link

java.nio.file.FileAlreadyExistsException: jquery-3.6.0.min.js #547

Closed stanio closed 1 year ago

stanio commented 1 year ago

Problem Statement

please read https://github.com/cbeust/testng-eclipse/blob/master/docs/Troubleshooting.md first

Running TestNG tests from a single project multiple times produces a confusing error message in the Console view at the end of the execution:

10:14:32.494 [main] ERROR org.testng.reporters.jq.Main - ...\test-output\jquery-3.6.0.min.js
java.nio.file.FileAlreadyExistsException: ...\test-output\jquery-3.6.0.min.js
    at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:87)
    at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
    at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:108)
    at java.base/sun.nio.fs.WindowsFileSystemProvider.newByteChannel(WindowsFileSystemProvider.java:235)
    at java.base/java.nio.file.spi.FileSystemProvider.newOutputStream(FileSystemProvider.java:478)
    at java.base/java.nio.file.Files.newOutputStream(Files.java:220)
    at java.base/java.nio.file.Files.copy(Files.java:3067)
    at org.testng.reporters.jq.Main.generateReport(Main.java:95)
    at org.testng.TestNG.generateReports(TestNG.java:1134)
    at org.testng.TestNG.run(TestNG.java:1072)
    at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:115)
    at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
    at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)

There are no test (or otherwise) failures indicated elsewhere. I've found I can just:

Preferences -> TestNG -> [x] Disable default listeners

as I don't really need HTML reports with the Eclipse plugin. Maybe have this as the default setting.

Any relate message in "Error Log" view

"Windows -> Show View -> Others -> Error Log"

None.

The Dependency Management tool for your project

Operating System

missedone commented 1 year ago

it should be fixed in testng 7.7.1, pls update the version in your build.gradle: org.testng:testng:7.7.1

stanio commented 1 year ago

Thank you. Haven't previously noticed there's a newer version available. Updating to testng 7.7.1 has eliminated the funny exception trace with the "[ ] Disable default listeners" option unchecked (the default).