diff options
author | Clyhtsuriva <61652557+clyhtsuriva@users.noreply.github.com> | 2021-06-27 11:02:03 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-27 11:02:03 +0000 |
commit | e13eea333d7af2786dbbbb5ed60cea4593d5ee12 (patch) | |
tree | d87270f2e9cee0586a3c7b49033cefaca0c107d0 /src/test/java/musichub/util/LogHandlerTest.java | |
parent | 18359e9e2892a332f283476bc3ae887308f51cec (diff) | |
parent | 9a234079437a1532072ed5f0bce0203922719b0f (diff) |
Merge pull request #10 from Said-Belhadj/feature/STZ-0012
Feature/stz 0012
Diffstat (limited to 'src/test/java/musichub/util/LogHandlerTest.java')
-rw-r--r-- | src/test/java/musichub/util/LogHandlerTest.java | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/src/test/java/musichub/util/LogHandlerTest.java b/src/test/java/musichub/util/LogHandlerTest.java index 17b47f6..ab8e160 100644 --- a/src/test/java/musichub/util/LogHandlerTest.java +++ b/src/test/java/musichub/util/LogHandlerTest.java @@ -12,30 +12,30 @@ import static org.junit.jupiter.api.Assertions.assertTrue; public class LogHandlerTest { @Test - void testWrite() { + void testLogHandlerClass() { try { - write("JUnit test", "INFO"); - } catch (IOException e) { - e.printStackTrace(); + LogHandler logHandlerClass = new LogHandler(); + } catch (Error e) { + assertTrue(e instanceof AssertionError); + assertEquals("You just can't instantiate this class.", e.getMessage()); } } @Test - void testRead() { + void testWrite() { try { - read(); + write("JUnit test", "TEST"); } catch (IOException e) { e.printStackTrace(); } } @Test - void testLogHandlerClass() { + void testRead() { try { - LogHandler logHandlerClass = new LogHandler(); - } catch (Error ex) { - assertTrue(ex instanceof AssertionError); - assertEquals("You just can't instantiate this class.", ex.getMessage()); + read(); + } catch (IOException e) { + e.printStackTrace(); } } } |