Ejemplo n.º 1
0
 /**
  * @covers ::resetOriginals
  */
 public function testResetOriginals()
 {
     $model = new City(['id' => 1, 'name' => 'test 2']);
     $expected = ['id' => 1, 'name' => 'test 2', 'countryId' => null];
     $model->name = 'test 3';
     $model->id = 4;
     $this->assertEquals($expected, $model->getOriginals());
     $model->resetOriginals();
     $expected = ['id' => 4, 'name' => 'test 3', 'countryId' => null];
     $this->assertEquals($expected, $model->getOriginals());
 }