22
33namespace Zenstruck \Console \Test ;
44
5- use PHPUnit \Framework \Assert as PHPUnit ;
65use Symfony \Component \VarDumper \VarDumper ;
6+ use Zenstruck \Assert ;
77
88/**
99 * @author Kevin Bond <kevinbond@gmail.com>
@@ -41,28 +41,28 @@ public function errorOutput(): string
4141
4242 public function assertOutputContains (string $ expected ): self
4343 {
44- PHPUnit:: assertStringContainsString ( $ expected , $ this ->output ());
44+ Assert:: that ( $ this ->output ())-> contains ( $ expected );
4545
4646 return $ this ;
4747 }
4848
4949 public function assertOutputNotContains (string $ expected ): self
5050 {
51- PHPUnit:: assertStringNotContainsString ( $ expected , $ this ->output ());
51+ Assert:: that ( $ this ->output ())-> doesNotContain ( $ expected );
5252
5353 return $ this ;
5454 }
5555
5656 public function assertErrorOutputContains (string $ expected ): self
5757 {
58- PHPUnit:: assertStringContainsString ( $ expected , $ this ->errorOutput ());
58+ Assert:: that ( $ this ->errorOutput ())-> contains ( $ expected );
5959
6060 return $ this ;
6161 }
6262
6363 public function assertErrorOutputNotContains (string $ expected ): self
6464 {
65- PHPUnit:: assertStringNotContainsString ( $ expected , $ this ->errorOutput ());
65+ Assert:: that ( $ this ->errorOutput ())-> doesNotContain ( $ expected );
6666
6767 return $ this ;
6868 }
@@ -74,7 +74,7 @@ public function assertSuccessful(): self
7474
7575 public function assertStatusCode (int $ expected ): self
7676 {
77- PHPUnit:: assertSame ( $ expected , $ this ->statusCode ());
77+ Assert:: that ( $ this ->statusCode ())-> is ( $ expected );
7878
7979 return $ this ;
8080 }
0 commit comments