http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java
File dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java
(right):

http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java#newcode295
dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java:295: if
(!cacheDirectory.exists() && !cacheDirectory.mkdir()) {
Instead of exists(), isDirectory().  If an ordinary file happens to be
in the way, you'll fall past this test and fail later.

http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java#newcode311
dev/core/src/com/google/gwt/dev/javac/PersistentUnitCache.java:311: //
ignore, we'll try again later in the writer thread.
Maybe we should go ahead and fail here.

http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java
File dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java
(right):

http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java#newcode178
dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java:178:
} catch (UnableToCompleteException ex) {
Typically, you'd put a fail() above this line, and rename 'ex' ->
'expected'.  Then you don't have to track via boolean.

http://gwt-code-reviews.appspot.com/1380808/diff/1/dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java#newcode186
dev/core/test/com/google/gwt/dev/javac/PersistentUnitCacheTest.java:186:

Would also be good to test what happens if you create an ordinary file
in the way of the directory.

http://gwt-code-reviews.appspot.com/1380808/

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to