public function testRemoveNotes()
 {
     $note1 = new NoteEntity();
     $note1->setId(1);
     $note2 = new NoteEntity();
     $note2->setId(2);
     $note3 = new NoteEntity();
     $note3->setId(3);
     $notes = new ArrayCollection();
     $notes->add($note1);
     $notes->add($note2);
     $notes->add($note3);
     $this->notes->setNotes($notes);
     $this->notes->removeNote($note1);
     $this->assertNotContains($note1, $this->notes->getNotes()->toArray());
 }
 public function testSetGetNotes()
 {
     $caseItemMock = $this->getMockedClass();
     $emptyCollection = $caseItemMock->getNotes()->toArray();
     $this->assertEmpty($emptyCollection);
     $noteCollection = new ArrayCollection();
     for ($i = 0; $i < 10; $i++) {
         $note = new Note();
         $note->setId($i);
         $noteCollection->add($note);
     }
     $caseItemMock->setNotes($noteCollection);
     $expected = 10;
     $array = $caseItemMock->getNotes()->toArray();
     $this->assertEquals($expected, count($array));
     for ($i = 0; $i < 10; $i++) {
         $note = $array[$i];
         $this->assertEquals($i, $note->getId());
     }
 }
 public function testGetSetId()
 {
     $id = 123;
     $this->note->setId($id);
     $this->assertEquals($id, $this->note->getId());
 }