assert() -> assertTrue() to reflect new Java reserved word.
git-svn-id: svn+ssh://src.earth.threerings.net/narya/trunk@1241 542714f4-19e9-0310-aa3c-eee0fc999fb1
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: FrameTest.java,v 1.6 2001/12/13 01:35:52 mdb Exp $
|
||||
// $Id: FrameTest.java,v 1.7 2002/04/15 16:34:36 shaper Exp $
|
||||
|
||||
package com.threerings.presents.io;
|
||||
|
||||
@@ -44,22 +44,22 @@ public class FrameTest extends TestCase
|
||||
|
||||
// read the first frame
|
||||
fin.readFrame(in);
|
||||
assert("string1", STRING1.equals(din.readUTF()));
|
||||
assert("string2", STRING2.equals(din.readUTF()));
|
||||
assert("string3", STRING3.equals(din.readUTF()));
|
||||
assert("hit eof", fin.read() == -1);
|
||||
assertTrue("string1", STRING1.equals(din.readUTF()));
|
||||
assertTrue("string2", STRING2.equals(din.readUTF()));
|
||||
assertTrue("string3", STRING3.equals(din.readUTF()));
|
||||
assertTrue("hit eof", fin.read() == -1);
|
||||
|
||||
// read the second frame
|
||||
fin.readFrame(in);
|
||||
assert("string4", STRING4.equals(din.readUTF()));
|
||||
assert("string5", STRING5.equals(din.readUTF()));
|
||||
assert("string6", STRING6.equals(din.readUTF()));
|
||||
assert("hit eof", fin.read() == -1);
|
||||
assertTrue("string4", STRING4.equals(din.readUTF()));
|
||||
assertTrue("string5", STRING5.equals(din.readUTF()));
|
||||
assertTrue("string6", STRING6.equals(din.readUTF()));
|
||||
assertTrue("hit eof", fin.read() == -1);
|
||||
|
||||
// read the third frame
|
||||
fin.readFrame(in);
|
||||
assert("string7", STRING7.equals(din.readUTF()));
|
||||
assert("hit eof", fin.read() == -1);
|
||||
assertTrue("string7", STRING7.equals(din.readUTF()));
|
||||
assertTrue("hit eof", fin.read() == -1);
|
||||
}
|
||||
|
||||
public void runTest ()
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: StreamableUtilTest.java,v 1.1 2002/03/20 22:58:26 mdb Exp $
|
||||
// $Id: StreamableUtilTest.java,v 1.2 2002/04/15 16:34:36 shaper Exp $
|
||||
|
||||
package com.threerings.presents.io;
|
||||
|
||||
@@ -105,7 +105,7 @@ public class StreamableUtilTest extends TestCase
|
||||
Boink[] nboinks = (Boink[])StreamableUtil.readStreamables(din);
|
||||
|
||||
// make sure all went well
|
||||
assert("boinks == nboinks", Arrays.equals(boinks, nboinks));
|
||||
assertTrue("boinks == nboinks", Arrays.equals(boinks, nboinks));
|
||||
|
||||
// System.out.println("nboinks: " + StringUtil.toString(nboinks));
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: DOMTest.java,v 1.8 2002/03/19 01:10:03 mdb Exp $
|
||||
// $Id: DOMTest.java,v 1.9 2002/04/15 16:34:36 shaper Exp $
|
||||
|
||||
package com.threerings.presents.server;
|
||||
|
||||
@@ -57,9 +57,9 @@ public class DOMTest extends TestCase
|
||||
|
||||
public void attributeChanged (AttributeChangedEvent event)
|
||||
{
|
||||
assert(fields[_fcount] + " == " + values[_fcount],
|
||||
event.getName().equals(fields[_fcount]) &&
|
||||
event.getValue().equals(values[_fcount]));
|
||||
assertTrue(fields[_fcount] + " == " + values[_fcount],
|
||||
event.getName().equals(fields[_fcount]) &&
|
||||
event.getValue().equals(values[_fcount]));
|
||||
|
||||
// shutdown once we receive our last update
|
||||
if (++_fcount == fields.length) {
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: DestroyedRefTest.java,v 1.7 2002/02/09 07:50:04 mdb Exp $
|
||||
// $Id: DestroyedRefTest.java,v 1.8 2002/04/15 16:34:36 shaper Exp $
|
||||
|
||||
package com.threerings.presents.server;
|
||||
|
||||
@@ -66,8 +66,8 @@ public class DestroyedRefTest
|
||||
|
||||
} else if (event instanceof ObjectAddedEvent &&
|
||||
toid == _objtwo.getOid()) {
|
||||
assert("list should contain only one oid",
|
||||
_objtwo.list.size() == 1);
|
||||
assertTrue("list should contain only one oid",
|
||||
_objtwo.list.size() == 1);
|
||||
|
||||
} else if (event instanceof AttributeChangedEvent) {
|
||||
// go bye bye
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
//
|
||||
// $Id: RefTest.java,v 1.7 2002/02/09 07:50:04 mdb Exp $
|
||||
// $Id: RefTest.java,v 1.8 2002/04/15 16:34:36 shaper Exp $
|
||||
|
||||
package com.threerings.presents.server;
|
||||
|
||||
@@ -59,7 +59,7 @@ public class RefTest
|
||||
} else if (event instanceof ObjectDestroyedEvent) {
|
||||
if (toid == _objtwo.getOid()) {
|
||||
// Log.info("List won't yet be empty: " + _objone.list);
|
||||
assert("List not empty", _objone.list.size() > 0);
|
||||
assertTrue("List not empty", _objone.list.size() > 0);
|
||||
} else {
|
||||
// Log.info("Other object destroyed.");
|
||||
// go bye bye
|
||||
@@ -68,7 +68,7 @@ public class RefTest
|
||||
|
||||
} else if (event instanceof ObjectRemovedEvent) {
|
||||
// Log.info("List should be empty: " + _objone.list);
|
||||
assert("List empty", _objone.list.size() == 0);
|
||||
assertTrue("List empty", _objone.list.size() == 0);
|
||||
// finally destroy the other object to complete the circle
|
||||
_objone.destroy();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user