TeamJava Forum
[ Read Responses | Post a New Response | Return to the Index ]
[ Previous | Next ]
cannot resolve symbol
Posted by Anupama on Thursday, 3 July 2003, at 3:43 a.m.
Hi,
While compiling my java code it is displaying an arror as 'cannot resolve symbol'.
I wrote this code as a testcase for a source code,the source code is compiled while the code written as a testcase is not compliled.
My code:
package junit.samples;
import java.text.ParseException;
import junit.framework.*;
public class IsoDateTest extends TestCase
{
IsoDate epoch;
IsoDate eon;
protected void setUp()
{
System.out.println("setUp()");
epoch=new IsoDate(0);
eon=new IsoDate(1000000000L*1000);
}
protected void tearDown()
{
System.out.println("tearDown");
}
public void testIsoDate() throws Exception
{
System.out.println("testIsoDate()");
assertEquals(epoch, new IsoDate("1970-01-00:00 GMT"));
assertEquals(eon, new IsoDate("2001-09-09 01:46:40 GMT"));
}
public void testtoString() throws Exception
{
System.out.println("testToString()");
assertequals("1970-01-01 00:00:00 GMT",epoch.tostring());
assertequals("2001-09-09 01:46:40 GMT",eon.tostring());
}
public static void main (String[] args)
{
junit.textui.TestRunner.run(IsoDateTest.class);
}
}
Error Message:
cannot resolve symbol
symbol:method tostring()
location:class junit.samples.IsoDate
Please help me by giving the solution
Thanks
Anupama
Responses
Post a New Response
The TeamJava Forum is maintained with WebBBS 2.24.