@@ -28,7 +28,7 @@ class RegisterListenersPassTest extends TestCase
2828 */
2929 public function testEventSubscriberWithoutInterface ()
3030 {
31- $ this ->expectException (' InvalidArgumentException ' );
31+ $ this ->expectException (\ InvalidArgumentException::class );
3232 $ builder = new ContainerBuilder ();
3333 $ builder ->register ('event_dispatcher ' );
3434 $ builder ->register ('my_event_subscriber ' , 'stdClass ' )
@@ -98,7 +98,7 @@ public function testAliasedEventSubscriber()
9898
9999 public function testAbstractEventListener ()
100100 {
101- $ this ->expectException (' InvalidArgumentException ' );
101+ $ this ->expectException (\ InvalidArgumentException::class );
102102 $ this ->expectExceptionMessage ('The service "foo" tagged "kernel.event_listener" must not be abstract. ' );
103103 $ container = new ContainerBuilder ();
104104 $ container ->register ('foo ' , 'stdClass ' )->setAbstract (true )->addTag ('kernel.event_listener ' , []);
@@ -110,7 +110,7 @@ public function testAbstractEventListener()
110110
111111 public function testAbstractEventSubscriber ()
112112 {
113- $ this ->expectException (' InvalidArgumentException ' );
113+ $ this ->expectException (\ InvalidArgumentException::class );
114114 $ this ->expectExceptionMessage ('The service "foo" tagged "kernel.event_subscriber" must not be abstract. ' );
115115 $ container = new ContainerBuilder ();
116116 $ container ->register ('foo ' , 'stdClass ' )->setAbstract (true )->addTag ('kernel.event_subscriber ' , []);
@@ -180,7 +180,7 @@ public function testNoPreloadEvents()
180180
181181 public function testEventSubscriberUnresolvableClassName ()
182182 {
183- $ this ->expectException (' InvalidArgumentException ' );
183+ $ this ->expectException (\ InvalidArgumentException::class );
184184 $ this ->expectExceptionMessage ('You have requested a non-existent parameter "subscriber.class" ' );
185185 $ container = new ContainerBuilder ();
186186 $ container ->register ('foo ' , '%subscriber.class% ' )->addTag ('kernel.event_subscriber ' , []);
0 commit comments