@Test
public void pathTestMaybePath() throws Exception {

  final Map<String, String> someMap = new HashMap<>();
  someMap.put("name", fakeFileName);
  someMap.put("extension", fakeExtension);
  when(state.getTokens())
      .thenReturn(someMap);
  String path = maybePath(state);
  assertThat(path, is(equalTo(fakeFileName + "." + fakeExtension)));
  someMap.put("path", fakePath);
  path = maybePath(state);
  assertThat(path, is(equalTo(fakePath + "/" + fakeFileName + "." + fakeExtension)));
}