Topic
  • No replies
SystemAdmin
SystemAdmin
210 Posts

Pinned topic Unable to compile the aceeptancetest using Fitnesse

‏2008-02-03T08:45:28Z |
I'm new to the testing environment.I just wanted to run a simple test using Fitnesse.I went through the userguide in the www.fitnesse.org There was a sample prog named ExampleAcceptanceTest. I downloaded the fitnesse and extracted it to f:\project\root.The fixture code is as follows

package myFixtures;
import fit.ColumnFixture;

public class rightTriangle extends ColumnFixture
{
public double a;
public double b;
public double c;
public boolean right()
{
return (a*a+b*b)==(c*c);
}
}
and saved it at this loc: F:\Project\root\fitnesse\FitNesseRoot\files\examples\myFixtures

the acceptance test goes something like this
<table class="jive-wiki-table">
<tr>
<td>myFixtures.rightTriangle</td>
</tr>
<tr>
<td>a</td>
<td>b</td>
<td>c</td>
<td>right()</td>
</tr>
<tr>
<td>3</td>
<td>4</td>
<td>5</td>
<td>true</td>
</tr>
<tr>
<td>6</td>
<td>8</td>
<td>10</td>
<td>true</td>
</tr>
<tr>
<td>3</td>
<td>5</td>
<td>9</td>
<td>false</td>
</tr>
</table>

----
ClassPath

The classpath is set to
classpath: fitnesse.jar
classpath: FitNesseRoot/files/examples

when i tried to compile the code at the loc
F:\Project\root\fitnesse\FitNesseRoot\files\examples\> javac -classpath fitness.jar
myFixtures\rightTriangle.java

i'm getting two errors something like this
myFixtures\rightTriangle.java:2:package fit does not exist
import fit.ColumnFixture;
myFixtures\rightTriangle.java:4:cannot find symbol
symbol: class ColumnFixture
public class rightTriangle extends ColumnFixture

2 errors

Can anyone please help me out in resolving this problem.I would expect a quick reply from the experienced users.