[ 
https://issues.apache.org/activemq/browse/CAMEL-1924?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=53685#action_53685
 ] 

Christian Schneider edited comment on CAMEL-1924 at 8/20/09 6:38 AM:
---------------------------------------------------------------------

I have found the problem in the first test that failed:
GenericFileDeleteProcessStrategyTest.testCannotDeleteFile

In the method exists file the test checks if the file name equals 
"target/foo/boom.txt" but on windows the file name is "target\foo\boom.txt". So 
the method says the file does not exist. The test then thinks it has 
successfully deleted the file and does not throw the expected exception. 

Claus remarked:
Good use the FileUtil.normalizePath to ensure the path can be tested
using equals.
There are other unit tests that does this as well.

      was (Author: [email protected]):
    I have found the problem in the first test that failed:
GenericFileDeleteProcessStrategyTest.testCannotDeleteFile

In the method exists file the test checks if the file name equals 
"target/foo/boom.txt" but on windows the file name is "target\foo\boom.txt". So 
the method says the file does not exist. The test then thinks it has 
successfully deleted the file and does not throw the expected exception. 
  
> Unit test failures on Windows in 2.0.0 release
> ----------------------------------------------
>
>                 Key: CAMEL-1924
>                 URL: https://issues.apache.org/activemq/browse/CAMEL-1924
>             Project: Apache Camel
>          Issue Type: Bug
>          Components: camel-core
>    Affects Versions: 2.0.0
>         Environment: Windows Vista 32 Bit, JDK 1.6.0_14 and maven 2.2.0
>            Reporter: Christian Schneider
>             Fix For: 2.1.0
>
>
> 3 failures in camel-core that do not seem to occur on linux and mac.
> Failure Details
>       testCannotDeleteFile
>       junit.framework.AssertionFailedError: Should have thrown an exception
>       
> org.apache.camel.component.file.strategy.GenericFileDeleteProcessStrategyTest:125
>       testCacheStreamToFileAndNotCloseStream
>       junit.framework.AssertionFailedError: we should have no temp file 
> expected:<1> but was:<0>
>       
> org.apache.camel.converter.stream.CachedOutputStreamTest:117
>       testRouteIsCorrectAtRuntime
>       junit.framework.AssertionFailedError: expected:<4> but was:<1>
>       
> org.apache.camel.processor.ChoiceWithEndTest:39

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to