diff --git a/src/test/java/org/example/AdminTest.java b/src/test/java/org/example/AdminTest.java index f844ece..e8fa2fa 100644 --- a/src/test/java/org/example/AdminTest.java +++ b/src/test/java/org/example/AdminTest.java @@ -36,10 +36,11 @@ class AdminTest { admin.writeToFile(admin, filename); - String content = Files.readString(Path.of(filename)); + Path path = Path.of(filename); + String content = Files.readString(path); assertEquals("Simon\nA1001\nAdmin", content); - Files.delete(Path.of(filename)); + Files.delete(path); }