Closed asivaneswaran closed 3 years ago
Both these assertions don't work when I do this:
public function testResponsibleCanViewOwnAssociationShow() { $this->be($this->responsible()); $association = Association::factory()->create([ 'responsible_1_id' => $this->responsible()->member_id, ]); $response = $this->novaDetail('associations', $association->id); $response->assertCanView(); }
I get this error:
Unable to find JSON fragment: [{"authorizedToView":true}]
And for this:
public function testResponsibleCannotViewOtherAssociationShow() { $this->be($this->responsible()); $association = Association::factory()->create([ 'responsible_1_id' => Member::factory(), ]); $response = $this->novaDetail('associations', $association->id); $response->assertCannotView(); }
Unable to find JSON fragment: [{"authorizedToView":false}]
But the response I get is a AccessDeniedHttpException, so technically the test should pass.
I am on the latest version.
Both these assertions don't work when I do this:
I get this error:
And for this:
I get this error:
But the response I get is a AccessDeniedHttpException, so technically the test should pass.
I am on the latest version.