diff options
author | Gunther6070 <haydenhartman10@yahoo.com> | 2025-03-03 17:06:40 -0500 |
---|---|---|
committer | Gunther6070 <haydenhartman10@yahoo.com> | 2025-03-03 17:06:40 -0500 |
commit | c80ffa3e32bb2cf119e1088ef0121fb2087eb107 (patch) | |
tree | 23c8c9918fecb7f7c1258c3fab0b2f0bf3a9610b /ufund-api/src/test/java | |
parent | acac4aba2f7876c557b466ae6578c7012419679b (diff) | |
download | JellySolutions-c80ffa3e32bb2cf119e1088ef0121fb2087eb107.tar.gz JellySolutions-c80ffa3e32bb2cf119e1088ef0121fb2087eb107.tar.bz2 JellySolutions-c80ffa3e32bb2cf119e1088ef0121fb2087eb107.zip |
Added maxGoal and setName tests
Diffstat (limited to 'ufund-api/src/test/java')
-rw-r--r-- | ufund-api/src/test/java/com/ufund/api/ufundapi/model/NeedTest.java | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/ufund-api/src/test/java/com/ufund/api/ufundapi/model/NeedTest.java b/ufund-api/src/test/java/com/ufund/api/ufundapi/model/NeedTest.java index 50b5cf2..ffcd808 100644 --- a/ufund-api/src/test/java/com/ufund/api/ufundapi/model/NeedTest.java +++ b/ufund-api/src/test/java/com/ufund/api/ufundapi/model/NeedTest.java @@ -59,6 +59,7 @@ public class NeedTest { assertEquals(need.getCurrent(), current); } + @Test public void testFilterAttributes() { @@ -75,4 +76,35 @@ public class NeedTest { assertEquals(need.getFilterAttributes(), filterAttributes); } + @Test + public void testSetMaxGoal() { + + String name = "Jellyfish"; + int id = 0; + double maxGoal = 100.00; + GoalType type = GoalType.MONETARY; + Need need = new Need(name, id, maxGoal, type); + + double newGoal = 200.00; + need.setMaxGoal(newGoal); + + + assertEquals(newGoal, need.getMaxGoal()); + } + + @Test + public void testSetName() { + + String name = "Jellyfish"; + int id = 0; + double maxGoal = 100.00; + GoalType type = GoalType.MONETARY; + Need need = new Need(name, id, maxGoal, type); + + String newName = "TESTINGFUN"; + need.setName(newName); + + assertEquals(newName, need.getName()); + } + } |