@Test
  public void errorSave() throws IOException {
    when(cache.getDirectory()).thenReturn(tmp.getRoot().toPath().resolve("unexistent_folder"));
    cacheStatus = new DefaultProjectCacheStatus(cache);

    exception.expect(IllegalStateException.class);
    exception.expectMessage("Failed to write cache sync status");
    cacheStatus.save();
  }
 @Before
 public void setUp() {
   when(cache.getDirectory()).thenReturn(tmp.getRoot().toPath());
   cacheStatus = new DefaultProjectCacheStatus(cache);
 }