I have a java program for the JUnit test, which I wrote in the netbeans IDE, where I am testing a class with a single thread. When I am going to compile this workflow and show the results 100%, but when I try to run this program, I get an exception, which is -
Testsuite: glb.chatmeter.crawler.yahoolocal.YahooBusinessDataTest Runs: 1, Errors: 1, Errors: 0, Elapsed time: 0.05 seconds.
Testcase: warning (junit.framework.TestSuite $ 1): FAILED No tests found in glb.chatmeter.crawler.yahoolocal.YahooBusinessDataTest junit.framework.AssertionFailedError: no tests found in glb.chatmeter.crawler.yahoolocal.YahooBusinessData
Testsuite: glb.chatmeter.crawler.yahoolocal.YahooBusinessDataTest Runs: 1, Errors: 0, Errors: 1, Elapsed time: 0 seconds
Testing: glb.chatmeter.crawler.yahoolocal.YahooBusinessDataTest: null: caused an error The Java VM plug-in failed abnormally. Please note that the time in the report does not reflect the time until the VM exits. junit.framework.AssertionFailedError: Forked Java VM failed abnormally. Please note that the time in the report does not reflect the time until the VM exits. at org.netbeans.core.execution.RunClassThread.run (RunClassThread.java:154)
Is this a netbean problem or something else? someone helped me thank you.
My code is this:
public class BusinessDataTest {
String url = "http://local.com/info-66122628-andy-richards-house-painting-mesa";
Integer[] locId = {1354};
String customerDetail ="Business Name";
public BusinessDataTest() {
}
@BeforeClass
public static void setUpClass() throws Exception {
}
@AfterClass
public static void tearDownClass() throws Exception {
}
@Test
public void testGetFullDataOfBusiness() {
System.out.println("getFullDataOfBusiness");
BusinessData instance = new BusinessData();
Integer expResult = 4;
Integer result = instance.getFullDataOfBusiness(url, customerDetail);
System.out.println("Result : " + result);
assertEquals(expResult, result);
}
}
source
share