Write tests - Write tests for what was done to this point that will be kept #11

Merged
okorpheus merged 61 commits from write-tests into master 2024-07-05 21:21:32 +00:00
2 changed files with 28 additions and 0 deletions
Showing only changes of commit 81b7e95b36 - Show all commits

View File

@ -38,6 +38,20 @@ it('submits a post request', function () {
'/form', '/form',
]); ]);
}); });
it('has a Create Student submit button', function () {
// Arrange
actingAs($this->adminUser);
// Act & Assert
$response = get(route('admin.students.create'));
$response->assertOk();
$response->assertSeeInOrder([
'button',
'type',
'submit',
'Create Student',
'/button',
], false);
});
it('has all needed fields', function () { it('has all needed fields', function () {
// Arrange // Arrange
actingAs($this->adminUser); actingAs($this->adminUser);

View File

@ -47,6 +47,20 @@ it('submits a post request', function () {
'/form', '/form',
]); ]);
}); });
it('has a Create User submit button', function () {
// Arrange
actingAs($this->adminUser);
// Act & Assert
$response = get(route('admin.users.create'));
$response->assertOk();
$response->assertSeeInOrder([
'button',
'type',
'submit',
'Create User',
'/button',
], false);
});
it('has all needed fields', function () { it('has all needed fields', function () {
// Arrange // Arrange
actingAs($this->adminUser); actingAs($this->adminUser);