Skip to content

Commit

Permalink
Remove assert during deleting models after test cleanup.
Browse files Browse the repository at this point in the history
- The assert was failing on Windows due to it being unable to
delete the model file.
  • Loading branch information
bhargav committed Apr 22, 2016
1 parent a49b6cb commit 3cebacc
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
1 change: 1 addition & 0 deletions appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ install:
- cmd: SET PATH=C:\maven\apache-maven-3.3.9\bin;%JAVA_HOME%\bin;%PATH:C:\Ruby193\bin;=%
- cmd: SET MAVEN_OPTS=-XX:MaxPermSize=2g -Xmx4g
- cmd: SET JAVA_OPTS=-XX:MaxPermSize=2g -Xmx4g
- cmd: SET org.ojalgo.OjAlgoUtils.ENVIRONMENT=x86_64
- cmd: mvn --version
- cmd: java -version
build_script:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,11 @@ public boolean accept(File dir, String name) {
return !name.endsWith(".lbj") && !name.startsWith(".nfs");
}
});
for (File file: dirFiles) assert file.delete() : "Could not delete file " + file;

for (File file: dirFiles) {
if (!file.delete()) {
System.out.println("Could not delete file " + file);
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,12 @@ public boolean accept(File dir, String name) {
return !name.endsWith(".lbj");
}
});
for (File file: dirFiles) assert file.delete() : "Could not delete file " + file;

for (File file: dirFiles) {
if (!file.delete()) {
System.out.println("Could not delete file " + file);
}
}
}

@SuppressWarnings({ "unchecked", "rawtypes" })
Expand Down

0 comments on commit 3cebacc

Please sign in to comment.