[Ginp-developers] My first changes
Brought to you by:
burchbri,
dougculnane
From: Brian B. <br...@Pi...> - 2007-01-05 14:02:01
|
Hi, Doug. Thanks for putting me onto the developers list. I've just committed three related changes and have fixed the "is a directory" exception in TestSetup. 1. I changed the already-successful TestGinpModel.setup() method to use the platform-independent file path separator. This minor refactoring allowed me to debug and understand the behaviour of the java.io.File class, which was not intuitively obvious and isn't well explained in ether the jdk5 javadoc, or my older java books. I added a couple of helpful comments. The Test class continued to run OK, so I committed the change. 2. I then debugged and refactored SetupManagerImpl and Configuration to implement the same logic. It tested successfully a) with /tmp/TestSetup/ missing, b) with /tmp/TestSetup/ present but ginp.xml missing, and c) with /tmp/TestSetup/ginp.xml already present. (We probably need 3 tests for these different cases, but I don't think it is important enough to do now - especially as I tested the cases manually and all 3 cases turn up randomly when running the tests). 3. I then changed the test configuration file path constants in both test classes to be os-independent. Maven now builds the war, but before I deploy it I'm going to try fixing the log4j failures in the unit tests. Regards, Brian |