diff --git a/.gitignore b/.gitignore index e90f753..1c3038f 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ target/* .classpath .project +*.iml diff --git a/src/main/java/LogginLab.java b/src/main/java/LogginLab.java index 11744ac..edc29f1 100644 --- a/src/main/java/LogginLab.java +++ b/src/main/java/LogginLab.java @@ -32,6 +32,9 @@ public boolean thresholdExceeds(Integer limit) { return (this.threshold > limit); } + public boolean thresholdReached(Integer limit) { + return (limit > this.threshold); + } // Write a method called thresholdReached, returns true if argument 'limit' is over the threshold. // Write a test for the method in the Test class. } diff --git a/src/test/java/LogginLabTest.java b/src/test/java/LogginLabTest.java index be1c95f..f2535b0 100644 --- a/src/test/java/LogginLabTest.java +++ b/src/test/java/LogginLabTest.java @@ -31,4 +31,13 @@ public void thresholdExceeds() { } } } + + @org.junit.Test + public void TestThresholdReached() { + LogginLab lab = new LogginLab(); + int limit = 3; + boolean result = lab.thresholdReached(limit); + assertTrue(result); + + } } \ No newline at end of file