mike clemow wrote:
// this doesn't work... //myCollection.pop() $ Event @=> Event f;
Are you sure that doesn't work? I swear I have been doing the same with my collection classes.
From ArrayListTest.ck:
class Foo
{
fun int foo()
{
return 1;
}
}
// unit test for ArrayList
class ArrayListTest extends Assert
{
{
true => exitOnFailure;
testConstructor();
testSize();
testGetAddSet();
testIterator();
testForEach();
testAssign();
testTransform();
testAddAll();
testFoo();
<<<"ArrayListTest ok">>>;
}
//...
fun void testFoo()
{
ArrayList list;
Foo fooIn;
list.add(fooIn);
list.get(0) $ Foo @=> Foo fooOut;
assertEquals(fooIn, fooOut);
<<