@@ -611,7 +611,7 @@ public function testPrototype()
611
611
$ resources = $ container ->getResources ();
612
612
613
613
$ fixturesDir = \dirname (__DIR__ ).\DIRECTORY_SEPARATOR .'Fixtures ' .\DIRECTORY_SEPARATOR ;
614
- $ this ->assertTrue ( false !== array_search ( new FileResource ($ fixturesDir .'xml ' .\DIRECTORY_SEPARATOR .'services_prototype.xml ' ), $ resources) );
614
+ $ this ->assertContains (( string ) new FileResource ($ fixturesDir .'xml ' .\DIRECTORY_SEPARATOR .'services_prototype.xml ' ), $ resources );
615
615
616
616
$ prototypeRealPath = \realpath (__DIR__ .\DIRECTORY_SEPARATOR .'.. ' .\DIRECTORY_SEPARATOR .'Fixtures ' .\DIRECTORY_SEPARATOR .'Prototype ' );
617
617
$ globResource = new GlobResource (
@@ -624,7 +624,7 @@ public function testPrototype()
624
624
str_replace (\DIRECTORY_SEPARATOR , '/ ' , $ prototypeRealPath .\DIRECTORY_SEPARATOR .'BadClasses ' ) => true ,
625
625
)
626
626
);
627
- $ this ->assertTrue ( false !== array_search ( $ globResource , $ resources) );
627
+ $ this ->assertContains (( string ) $ globResource , $ resources );
628
628
$ resources = array_map ('strval ' , $ resources );
629
629
$ this ->assertContains ('reflection.Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo ' , $ resources );
630
630
$ this ->assertContains ('reflection.Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar ' , $ resources );
@@ -643,7 +643,7 @@ public function testPrototypeExcludeWithArray()
643
643
$ resources = $ container ->getResources ();
644
644
645
645
$ fixturesDir = \dirname (__DIR__ ).\DIRECTORY_SEPARATOR .'Fixtures ' .\DIRECTORY_SEPARATOR ;
646
- $ this ->assertTrue ( false !== array_search ( new FileResource ($ fixturesDir .'xml ' .\DIRECTORY_SEPARATOR .'services_prototype_array.xml ' ), $ resources) );
646
+ $ this ->assertContains (( string ) new FileResource ($ fixturesDir .'xml ' .\DIRECTORY_SEPARATOR .'services_prototype_array.xml ' ), $ resources );
647
647
648
648
$ prototypeRealPath = realpath (__DIR__ .\DIRECTORY_SEPARATOR .'.. ' .\DIRECTORY_SEPARATOR .'Fixtures ' .\DIRECTORY_SEPARATOR .'Prototype ' );
649
649
$ globResource = new GlobResource (
@@ -656,7 +656,7 @@ public function testPrototypeExcludeWithArray()
656
656
str_replace (\DIRECTORY_SEPARATOR , '/ ' , $ prototypeRealPath .\DIRECTORY_SEPARATOR .'OtherDir ' ) => true ,
657
657
)
658
658
);
659
- $ this ->assertTrue ( false !== array_search ( $ globResource , $ resources) );
659
+ $ this ->assertContains (( string ) $ globResource , $ resources );
660
660
$ resources = array_map ('strval ' , $ resources );
661
661
$ this ->assertContains ('reflection.Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Foo ' , $ resources );
662
662
$ this ->assertContains ('reflection.Symfony\Component\DependencyInjection\Tests\Fixtures\Prototype\Sub\Bar ' , $ resources );
0 commit comments