Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Windows] The filename, directory name, or volume label syntax is incorrect for *.html report #140

Closed
polok opened this issue Oct 24, 2013 · 6 comments · Fixed by #141
Closed

Comments

@polok
Copy link

polok commented Oct 24, 2013

I am trying to run test by spoon on windows 7 machine but unfortunately something is wrong with the path to *.html reports for each test case.

I use spoon runner in version - 1.0.5 I am getting such error (the test are running on emulator fine)

[SR.runTests] Executing instrumentation suite on 1 device(s).
Exception in thread "main" java.lang.RuntimeException: java.io.FileNotFoundException: spoon-output\logs\192.168.56.102:5555\simeTest.html (The filename, directory name,
        at com.squareup.spoon.html.HtmlRenderer.renderMustacheToFile(HtmlRenderer.java:150)
        at com.squareup.spoon.html.HtmlRenderer.generateLogHtml(HtmlRenderer.java:138)
        at com.squareup.spoon.html.HtmlRenderer.render(HtmlRenderer.java:58)
        at com.squareup.spoon.SpoonRunner.run(SpoonRunner.java:80)
        at com.squareup.spoon.SpoonRunner.main(SpoonRunner.java:376)
Caused by: java.io.FileNotFoundException: spoon-output\logs\192.168.56.102:5555\simpleTest.html (The filename, directory name, or volume label syntax is incorrect)
        at java.io.FileOutputStream.open(Native Method)
        at java.io.FileOutputStream.<init>(Unknown Source)
        at java.io.FileOutputStream.<init>(Unknown Source)
        at java.io.FileWriter.<init>(Unknown Source)
        at com.squareup.spoon.html.HtmlRenderer.renderMustacheToFile(HtmlRenderer.java:147)
        ... 4 more

What I can see is that html files for each test case are under 'test' directory not 'logs' but also without 192... directory so it can be also a problem when we try to run tests on few devices (we are using genymotion for this).

When I display 'index.html' I can see such error:

com.android.ddmlib.SyncException: Target directory doesn't exist.
    at com.android.ddmlib.SyncService.pull(SyncService.java:250)
    at com.squareup.spoon.SpoonDeviceRunner.run(SpoonDeviceRunner.java:215)
    at com.squareup.spoon.SpoonRunner.runTests(SpoonRunner.java:111)
    at com.squareup.spoon.SpoonRunner.run(SpoonRunner.java:78)
    at com.squareup.spoon.SpoonRunner.main(SpoonRunner.java:376)
@JakeWharton
Copy link
Member

Windows doesn't allow colons in file or directory names. Your use of
Genymotion causes this. It's an easy fix that I'll get in tomorrow.
On Oct 24, 2013 12:09 AM, "polok" notifications@github.com wrote:

I am trying to run test by spoon on windows 7 machine but unfortunately
something is wrong with the path to *.html reports for each test case.

I use spoon runner in version - 1.0.5 I am getting such error (the test
are running on emulator fine)

[SR.runTests] Executing instrumentation suite on 1 device(s).
Exception in thread "main" java.lang.RuntimeException: java.io.FileNotFoundException: spoon-output\logs\192.168.56.102:5555\simeTest.html (The filename, directory name,
at com.squareup.spoon.html.HtmlRenderer.renderMustacheToFile(HtmlRenderer.java:150)
at com.squareup.spoon.html.HtmlRenderer.generateLogHtml(HtmlRenderer.java:138)
at com.squareup.spoon.html.HtmlRenderer.render(HtmlRenderer.java:58)
at com.squareup.spoon.SpoonRunner.run(SpoonRunner.java:80)
at com.squareup.spoon.SpoonRunner.main(SpoonRunner.java:376)
Caused by: java.io.FileNotFoundException: spoon-output\logs\192.168.56.102:5555\simpleTest.html (The filename, directory name, or volume label syntax is incorrect)
at java.io.FileOutputStream.open(Native Method)
at java.io.FileOutputStream.(Unknown Source)
at java.io.FileOutputStream.(Unknown Source)
at java.io.FileWriter.(Unknown Source)
at com.squareup.spoon.html.HtmlRenderer.renderMustacheToFile(HtmlRenderer.java:147)
... 4 more

What I can see is that html files for each test case are under 'test'
directory not 'logs' but also without 192... directory so it can be also a
problem when we try to run tests on few devices (we are using genymotion
for this).


Reply to this email directly or view it on GitHubhttps://github.com//issues/140
.

@polok
Copy link
Author

polok commented Oct 24, 2013

Thanks a lot !!!

@polok
Copy link
Author

polok commented Oct 24, 2013

@JakeWharton Just to confirm, using Google's emulator it works. I will wait for your fix because this 'fast speed' is killing me and my tests :)

@JakeWharton
Copy link
Member

What version are you using? We already guard against this in SpoonUtils.sanitizeSerial.

@JakeWharton
Copy link
Member

Wait, I lied. The bug is still there due to a refactor.

@polok
Copy link
Author

polok commented Oct 25, 2013

Thanks! I will test this later today.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants