add dusk tests
This commit is contained in:
27
tests/Browser/Project/ProjectTest.php
Normal file
27
tests/Browser/Project/ProjectTest.php
Normal file
@@ -0,0 +1,27 @@
|
||||
<?php
|
||||
|
||||
namespace Tests\Browser;
|
||||
|
||||
use Laravel\Dusk\Browser;
|
||||
use Tests\DuskTestCase;
|
||||
use Throwable;
|
||||
|
||||
class ProjectTest extends DuskTestCase
|
||||
{
|
||||
/**
|
||||
* A basic test for the projects page.
|
||||
* Login with the test user and assert that the user is redirected to the projects page.
|
||||
*
|
||||
* @return void
|
||||
*
|
||||
* @throws Throwable
|
||||
*/
|
||||
public function testLogin()
|
||||
{
|
||||
$this->browse(function (Browser $browser) {
|
||||
$browser->loginWithRootUser()
|
||||
->visit('/projects')
|
||||
->assertSee('Projects');
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user