File tree Expand file tree Collapse file tree 1 file changed +18
-0
lines changed
Expand file tree Collapse file tree 1 file changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -53,6 +53,24 @@ public function testMigrate(): void
5353 $ this ->assertStringContainsString ('Migrations complete. ' , $ this ->getBuffer ());
5454 }
5555
56+ public function testMigrateRollbackValidBatchNumber (): void
57+ {
58+ command ('migrate --all ' );
59+ $ this ->clearBuffer ();
60+
61+ command ('migrate:rollback -b 1 ' );
62+ $ this ->assertStringContainsString ('Done rolling back migrations. ' , $ this ->getBuffer ());
63+ }
64+
65+ public function testMigrateRollbackInvalidBatchNumber (): void
66+ {
67+ command ('migrate --all ' );
68+ $ this ->clearBuffer ();
69+
70+ command ('migrate:rollback -b x ' );
71+ $ this ->assertStringContainsString ('Invalid batch number: x ' , $ this ->getBuffer ());
72+ }
73+
5674 public function testMigrateRollback (): void
5775 {
5876 command ('migrate --all -g tests ' );
You can’t perform that action at this time.
0 commit comments