directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pierre-Arnaud Marcelot (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (DIRSERVER-1549) Use JUnit TemporaryFolder Rule
Date Fri, 26 Aug 2011 16:26:33 GMT

     [ https://issues.apache.org/jira/browse/DIRSERVER-1549?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Pierre-Arnaud Marcelot updated DIRSERVER-1549:
----------------------------------------------

    Fix Version/s:     (was: 2.0.0-M2)
                   2.0.0-M3

> Use JUnit TemporaryFolder Rule
> ------------------------------
>
>                 Key: DIRSERVER-1549
>                 URL: https://issues.apache.org/jira/browse/DIRSERVER-1549
>             Project: Directory ApacheDS
>          Issue Type: Improvement
>            Reporter: Stefan Seelmann
>            Assignee: Stefan Seelmann
>             Fix For: 2.0.0-M3
>
>
> In many tests we need to create temporary files and folders. We use methods like:
>   File.createTempFile() 
>   File.deleteOnExit() 
>   File.delete()
>   org.apache.commons.io.FileUtils.deleteDirectory()
> JUnit 4.7 introduced the TemporaryFolder Rule: http://kentbeck.github.com/junit/javadoc/latest/org/junit/rules/TemporaryFolder.html
that guarantees that files and folders are delteted after each test. We should use this rule
and remove all handmade temporary file code.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message