assertRedirect(route('home')); actAsAdmin(); get(route('entry-flags.noShowSelect')) ->assertOk(); actAsTab(); get(route('entry-flags.noShowSelect')) ->assertOk(); actAsNormal(); get(route('entry-flags.noShowSelect')) ->assertRedirect(route('dashboard')) ->assertSessionHas('error', 'You are not authorized to perform this action'); }); it('has an input for entry_id', function () { actAsAdmin(); get(route('entry-flags.noShowSelect')) ->assertOk() ->assertElementExists('#entry_id', function (AssertElement $element) { $element->is('input'); }); }); it('submits to entry-flags.confirmNoShow', function () { actAsAdmin(); get(route('entry-flags.noShowSelect')) ->assertOk() ->assertFormExists('#entry-select-form', function (AssertForm $form) { $form->hasMethod('GET') ->hasAction(route('entry-flags.confirmNoShow')); }); });