java - Class Not Found: Empty Test Suite in IntelliJ -


i'm starting computer science program @ college, , i'm having issues intellij. when try run unit tests, message

process finished exit code 1 class not found: "edu.macalester.comp124.hw0.areatest"empty test suite. 

i see message entitled "no tests found" on left side of screen. test code here:

package edu.macalester.comp124.hw0;   import org.junit.test; import static org.junit.assert.*;  public class areatest {      @test     public void testsquare() {     assertequals(area.getsquarearea(3.0), 9.0, 0.001);     }      @test     public void testcircle() {     assertequals(area.getcirclearea(3.0), 28.2743, 0.001);     } } 

and project code here:

package edu.macalester.comp124.hw0;  import java.lang.math; public class area {  /**  * calculates area of square.  * @param sidelength length of side of square  * @return area  */ public static double getsquarearea(double sidelength) {     // has been replaced correct formula     return sidelength * sidelength; }  /**  * calculates area of circle.  * @param radius radius of circle  * @return area  */ public static double getcirclearea(double radius) {     // replaced correct value     return radius * 2 * math.pi; }  } 

how can tests work? in advance. i'm using recent version of intellij idea ce.

had same message. had remove run/debug configuration.

in case, ran unit test local test before. after moved test androidtest package , tried run again. android studio remembered last run configuration tried run again local unit test produced same error.

after removing config , running test again generated new configuration , worked.

enter image description here


Comments