Add test for non existing cache file, issue #921

This commit is contained in:
Michal Kordas 2015-04-15 19:02:38 +02:00 committed by Roman Ivanov
parent 1c42e3eeb9
commit b798438ecd
1 changed files with 8 additions and 0 deletions

View File

@ -130,4 +130,12 @@ public class TreeWalkerTest extends BaseCheckTestSupport
treeWalker.setTabWidth(1);
treeWalker.setCacheFile(temporaryFolder.newFile().getPath());
}
@Test
public void testNonExistingCacheFileDoesNotThrowException()
{
final TreeWalker treeWalker = new TreeWalker();
treeWalker.setCacheFile("/invalid");
treeWalker.destroy();
}
}