public static void deleteIfExists(final File file)
    {
        try
        {
            Files.deleteIfExists(file.toPath());
        }
        catch (final IOException ex)
        {
            LangUtil.rethrowUnchecked(ex);
        }
    }
@Test
    void deleteIfExistsNonExistingFile()
    {
        final Path file = tempDir.resolve("non-existing.txt");

        IoUtil.deleteIfExists(file.toFile());

        assertFalse(Files.exists(file));
    }