public function testSimpleLoop() { $Loop = new Loop(new Object(array(Object::TIME => array(0, 1, 2, 3, 4, 5)))); $i = 0; while ($Loop->nextStep()) { $i++; $this->assertEquals($i, $Loop->time()); } $this->assertTrue($Loop->isAtEnd()); }