Wed, 26 Aug 2020 19:09:07 +0200
fixes wrong call of assertEquals()
package de.uapcore.sudoku; import org.junit.jupiter.api.AfterEach; import org.junit.jupiter.api.BeforeEach; import org.junit.jupiter.api.Test; import javax.swing.*; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.junit.jupiter.api.Assertions.assertTrue; class SudokuTest { private Sudoku subject; @BeforeEach void init() { subject = new Sudoku(); } @AfterEach void destroy() { subject.setDefaultCloseOperation(WindowConstants.DO_NOTHING_ON_CLOSE); subject.dispose(); } @Test void testDefaultCloseOperation() { assertEquals(WindowConstants.EXIT_ON_CLOSE, subject.getDefaultCloseOperation()); } @Test void testMinimumSize() { assertEquals(subject.getSize(), subject.getMinimumSize()); } @Test void testLocationByPlattform() { assertTrue(subject.isLocationByPlatform()); } }