Bugfixes with != instead of equals and default toString calls

This commit is contained in:
vraskulin 2017-02-15 19:52:20 +03:00
parent 752392fc46
commit a15220d51e
74 changed files with 187 additions and 147 deletions

View file

@ -10,6 +10,8 @@ import org.junit.Rule;
import org.junit.Test;
import org.junit.rules.ExpectedException;
import java.util.Objects;
/**
* Custom unit tests for {link Mana}.
*
@ -525,7 +527,7 @@ public class ManaTest {
// then
assertEquals(mana, copy); // are equal
assertFalse(mana == copy); // are not the same object
assertFalse(Objects.equals(mana, copy)); // are not the same object
}
@Test
@ -603,7 +605,7 @@ public class ManaTest {
// then
assertEquals(mana, newMana);
assertFalse(mana == newMana);
assertFalse(Objects.equals(mana, newMana));
}
@Test