April 05
Prof. Ismael H. F. Santos -  ismael@tecgraf.puc-rio.br                                                          2
A JUnit 4 Test Case
n /** Test of setName() method, of class Value  */
n
n @Test
n public void createAndSetName()
n {       
n        Value v1 = new Value();
n
n        v1.setName( "Y" );
n
n        String expected = "Y"
n        String actual = v1.getName( );
n
n        Assert.assertEquals( expected, actual );
n }
Check to see that the
Value object really
did store the name