WIZARD_PR2_DOP/Test/Domain/Karten/NarrenkarteTest.java

40 lines
964 B
Java

/*
============================================================
This is the "NarrenkarteTest" file from Author: Philipp Kotte
written on: 10 / 10 / 2023 at: 21:18
============================================================
*/
package Test.Domain.Karten;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertTrue;
import org.junit.Test;
import Domain.Karten.Narrenkarte;
public class NarrenkarteTest {
@Test
public void vierNarren() {
Narrenkarte n1 = new Narrenkarte(5);
Narrenkarte n2 = new Narrenkarte(6);
Narrenkarte n3 = new Narrenkarte(7);
Narrenkarte n4 = new Narrenkarte(8);
assertEquals(n1.getName(), "Narr");
assertTrue(5 == n1.getId());
assertEquals(n2.getName(), "Narr");
assertTrue(6 == n2.getId());
assertEquals(n3.getName(), "Narr");
assertTrue(7 == n3.getId());
assertEquals(n4.getName(), "Narr");
assertTrue(8 == n4.getId());
assertEquals("ID 5: Narr", n1.toString());
}
}