@@ -9,9 +9,7 @@ public function testFormFlow(): void
99 $ client = self ::createClient ();
1010 $ crawler = $ client ->request ('GET ' , '/basic ' );
1111
12- self ::assertResponseIsSuccessful ();
13- self ::assertResponseFormatSame ('html ' );
14- self ::assertResponseStatusCodeSame (200 );
12+ self ::assertSame (200 , $ client ->getInternalResponse ()->getStatusCode ());
1513 self ::assertStringContainsString ('>Step1< ' , $ crawler ->html ());
1614 self ::assertSameFileContent ('step1.html ' , $ client ->getInternalResponse ()->getContent ());
1715
@@ -20,9 +18,7 @@ public function testFormFlow(): void
2018 'multistep[navigator][next] ' => '' ,
2119 ]);
2220
23- self ::assertResponseIsSuccessful ();
24- self ::assertResponseFormatSame ('html ' );
25- self ::assertResponseStatusCodeSame (200 );
21+ self ::assertSame (200 , $ client ->getInternalResponse ()->getStatusCode ());
2622 self ::assertStringContainsString ('>Step2< ' , $ crawler ->html ());
2723 self ::assertSameFileContent ('step2.html ' , $ crawler ->filter ('body ' )->html ());
2824
@@ -32,9 +28,7 @@ public function testFormFlow(): void
3228 'multistep[navigator][next] ' => '' ,
3329 ]);
3430
35- self ::assertResponseIsSuccessful ();
36- self ::assertResponseFormatSame ('html ' );
37- self ::assertResponseStatusCodeSame (200 );
31+ self ::assertSame (200 , $ client ->getInternalResponse ()->getStatusCode ());
3832 self ::assertStringContainsString ('>Step3< ' , $ crawler ->html ());
3933 self ::assertSameFileContent ('step3.html ' , $ crawler ->filter ('body ' )->html ());
4034
@@ -45,7 +39,8 @@ public function testFormFlow(): void
4539 'multistep[navigator][finish] ' => '' ,
4640 ]);
4741
48- self ::assertResponseRedirects ('/basic/success ' , 302 );
42+ self ::assertSame (302 , $ client ->getInternalResponse ()->getStatusCode ());
43+ self ::assertSame ('/basic/success ' , $ client ->getInternalResponse ()->getHeader ('Location ' ));
4944 }
5045
5146 private static function assertSameFileContent (string $ expectedFilename , string $ actualContent , bool $ save = false ): void
0 commit comments