@Test
public void testGetDate() throws IOException, NoSuchAlgorithmException {

    createFile(tempFile, 0);
    // Asserts that the date changes when the file is modified
    long date = tempFile.getDate();
    sleep(1000);    // Sleep a full second, some filesystems may only have a one-second granularity
    createFile(tempFile, 1);  // 1 byte should be enough
    assert tempFile.getDate()>date;
}