public function testObjectStateListVisitsChildren()
{
$visitor = $this->getVisitor();
$generator = $this->getGenerator();
$generator->startDocument(null);
$objectStateList = new ObjectStateList(array(new ObjectState(), new ObjectState()), 42);
$this->getVisitorMock()->expects($this->exactly(2))->method('visitValueObject')->with($this->isInstanceOf('eZ\\Publish\\Core\\REST\\Common\\Values\\RestObjectState'));
$visitor->visit($this->getVisitorMock(), $generator, $objectStateList);
}