diff --git a/.gitignore b/.gitignore index 7579f74..f0dcfe4 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ vendor composer.lock +tests/.phpunit.result.cache diff --git a/tests/AbstractTestCase.php b/tests/AbstractTestCase.php index 66b90a8..740a723 100644 --- a/tests/AbstractTestCase.php +++ b/tests/AbstractTestCase.php @@ -22,7 +22,7 @@ protected function assertVastDocumentSameWithXmlFixture($expectedXmlFixturePath, { $this->assertXmlStringEqualsXmlFile( $this->getFullXMLFixturePath($expectedXmlFixturePath), - $actualXmlDomDocument->toDomDocument() + (string)$actualXmlDomDocument ); } } diff --git a/tests/DocumentTest.php b/tests/DocumentTest.php index c4bcc3b..3c8a235 100644 --- a/tests/DocumentTest.php +++ b/tests/DocumentTest.php @@ -238,11 +238,10 @@ public function testCreateAdSectionWithDelivery() /** * Test for creating media file with invalid delivery - * @expectedException \Exception - * @expectedExceptionMessage Wrong delivery specified */ public function testCreateAdSectionWithInvalidDelivery() { + $this->expectExceptionMessage('Wrong delivery specified'); $factory = new Factory(); $document = $factory->create('2.0'); @@ -453,8 +452,8 @@ public function testToString() $factory = new Factory(); $document = $factory->create('2.0'); - $this->assertContains('', (string)$document); - $this->assertContains('', (string)$document); + $this->assertStringContainsString('', (string)$document); + $this->assertStringContainsString('', (string)$document); } /**