samples/effectivelist/test/org/apidesign/effectivelist/ListTest.scala
changeset 403 ebe08056c60c
parent 402 e25dbfce40e9
     1.1 --- a/samples/effectivelist/test/org/apidesign/effectivelist/ListTest.scala	Fri Aug 31 20:16:57 2012 +0200
     1.2 +++ b/samples/effectivelist/test/org/apidesign/effectivelist/ListTest.scala	Sun Sep 02 22:00:13 2012 +0200
     1.3 @@ -4,6 +4,7 @@
     1.4  import Assert._
     1.5  
     1.6  class ListTest {
     1.7 +  // BEGIN: effectivelist.person
     1.8    case class Person(name : String, age : Int) extends Listable[Person]
     1.9    
    1.10    var list : List[Person] = _
    1.11 @@ -28,6 +29,7 @@
    1.12      assertEquals("Anna was inserted 3rd", "Anna", list.get(2).name)
    1.13      assertEquals("Anna was inserted 4th", 6, list.get(3).age)
    1.14    }
    1.15 +  // END: effectivelist.person
    1.16  
    1.17    @Test def addFewAndThenTryToRemoveHead() = {
    1.18      assertTrue(list.add(p1))