Methods Summary |
---|
public static void | main(java.lang.String[] args)
if (args.length == 0){
junit.textui.TestRunner.run(FrameHolderTest.class);
} else {
junit.textui.TestRunner.run(makeSuite(args));
}
|
private static junit.framework.TestSuite | makeSuite(java.lang.String[] args)
final TestSuite ts = new TestSuite();
for (int i = 0; i < args.length; i++){
ts.addTest(new FrameHolderTest(args[i]));
}
return ts;
|
private void | nyi()
fail("Not Yet Implemented");
|
protected void | setUp()
|
protected void | tearDown()
|
public void | testBasics()
FrameHolder fh = new FrameHolder();
assertNotNull(fh.getDomainFrame());
fh.getDomainFrame().put("k", "v");
assertNotNull(fh.getConfigFrame("config0"));
fh.getConfigFrame("config0").inheritFrom(fh.getDomainFrame());
assertEquals("v", fh.getConfigFrame("config0").lookup("k"));
assertNotNull(fh.getConfigFrame("config1"));
assertFalse(fh.getConfigFrame("config0").equals(fh.getConfigFrame("config1")));
assertNotNull(fh.getServerFrame("frame0"));
fh.getServerFrame("frame0").inheritFrom(fh.getConfigFrame("config0"));
assertEquals("v", fh.getServerFrame("frame0").lookup("k"));
assertNotNull(fh.getClusterFrame("frame0"));
fh.getConfigFrame("config1").put("k", "config");
fh.getClusterFrame("frame0").inheritFrom(fh.getConfigFrame("config1"));
fh.getServerFrame("frame1").inheritFrom(fh.getClusterFrame("frame0"));
assertEquals("config", fh.getServerFrame("frame1").lookup("k"));
|
public void | testEquality()
FrameHolder fh1 = new FrameHolder();
FrameHolder fh2 = new FrameHolder();
assertEquals(fh1, fh2);
assertFalse(fh1.equals(new Object()));
assertFalse(fh1.equals(null));
assertEquals(fh1, fh1);
fh1.getDomainFrame().put("k", "v");
assertFalse(fh1.equals(fh2));
assertFalse(fh2.equals(fh1));
|