Hi,
ovirt engine master make with UT enabled is failing with the following error :
11:08:31,288 ERROR [ServletUtils] Error sending file
"/doesnotexist/iamprettysure".
java.io.FileNotFoundException: /doesnotexist/iamprettysure (No such file or directory)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:146)
at
org.ovirt.engine.core.utils.servlet.ServletUtils.writeFileToStream(ServletUtils.java:152)
at
org.ovirt.engine.core.utils.servlet.ServletUtilsTest.testWriteFileToStream_IOException(ServletUtilsTest.java:99)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.junit.runners.model.FrameworkMethod$1.runReflectiveCall(FrameworkMethod.java:45)
at org.junit.internal.runners.model.ReflectiveCallable.run(ReflectiveCallable.java:15)
at org.junit.runners.model.FrameworkMethod.invokeExplosively(FrameworkMethod.java:42)
at org.junit.internal.runners.statements.InvokeMethod.evaluate(InvokeMethod.java:20)
at org.junit.runners.ParentRunner.runLeaf(ParentRunner.java:263)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:68)
at org.junit.runners.BlockJUnit4ClassRunner.runChild(BlockJUnit4ClassRunner.java:47)
at org.junit.runners.ParentRunner$3.run(ParentRunner.java:231)
at org.junit.runners.ParentRunner$1.schedule(ParentRunner.java:60)
at org.junit.runners.ParentRunner.runChildren(ParentRunner.java:229)
at org.junit.runners.ParentRunner.access$000(ParentRunner.java:50)
at org.junit.runners.ParentRunner$2.evaluate(ParentRunner.java:222)
at org.junit.runners.ParentRunner.run(ParentRunner.java:300)
at org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:35)
at
org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:115)
at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:97)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at
org.apache.maven.surefire.booter.ProviderFactory$ClassLoaderProxy.invoke(ProviderFactory.java:103)
at com.sun.proxy.$Proxy0.invoke(Unknown Source)
at
org.apache.maven.surefire.booter.SurefireStarter.invokeProvider(SurefireStarter.java:150)
at
org.apache.maven.surefire.booter.SurefireStarter.runSuitesInProcess(SurefireStarter.java:91)
at org.apache.maven.surefire.booter.ForkedBooter.main(ForkedBooter.java:69)
11:08:31,290 ERROR [ServletUtils] The path is 1300 characters long, which is longer than
the maximum allowed 512.
11:08:31,290 ERROR [ServletUtils] The path contains potentially dangerous directory
navigation sequences.
11:08:31,290 ERROR [ServletUtils] The path contains potentially dangerous directory
navigation sequences.
11:08:31,290 ERROR [ServletUtils] The path contains potentially dangerous directory
navigation sequences.
11:08:31,290 ERROR [ServletUtils] The path contains potentially dangerous directory
navigation sequences.
11:08:31,290 ERROR [ServletUtils] The path "/../hosts" is not sane, will return
null.
11:08:31,299 ERROR [ServletUtils] Can't read file "/etc/doesntexist" for
request "null", will send a 404 error response.
Tests run: 22, Failures: 1, Errors: 0, Skipped: 0, Time elapsed: 0.194 sec <<<
FAILURE!
Running org.ovirt.engine.core.utils.servlet.DocsServletTest
Tests run: 1, Failures: 0, Errors: 0, Skipped: 1, Time elapsed: 0.001 sec
Running org.ovirt.engine.core.utils.servlet.LocaleFilterTest
Tests run: 8, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.03 sec
Running org.ovirt.engine.core.utils.servlet.FileServletTest
11:08:31,502 ERROR [FileServlet] Can't get base name from parameter "file".
11:08:31,505 ERROR [ServletUtils] Can't read file "" for request
"null", will send a 404 error response.
11:08:31,512 INFO [FileServlet] Index is
"/home/ababu/git-srcs/ovirt-engine/backend/manager/modules/utils/target/test-classes/org/ovirt/engine/core/utils/servlet/index.html".
11:08:31,512 ERROR [FileServlet] There is no index page for directory
"/home/ababu/git-srcs/ovirt-engine/backend/manager/modules/utils/target/test-classes/org/ovirt/engine/core/utils/servlet",
will send a 404 error response.
11:08:31,514 INFO [FileServlet] Index is
"/home/ababu/git-srcs/ovirt-engine/backend/manager/modules/utils/target/test-classes/org/ovirt/engine/core/utils/servlet/filetest/index.html".
11:08:31,517 INFO [FileServlet] Index is
"/home/ababu/git-srcs/ovirt-engine/backend/manager/modules/utils/target/test-classes/org/ovirt/engine/core/utils/servlet/filetest/index.html".
Tests run: 9, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.027 sec
Running org.ovirt.engine.core.utils.LocaleUtilsTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.002 sec
Running org.ovirt.engine.core.utils.archivers.tar.TarTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.024 sec
Running org.ovirt.engine.core.utils.FileUtilTest
Tests run: 2, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0.124 sec
Results :
Failed tests:
testCanReadFile(org.ovirt.engine.core.utils.servlet.ServletUtilsTest): We should not be
able to read this file.
Tests run: 275, Failures: 1, Errors: 0, Skipped: 2