enhanced plugin support (#634)

- refactored admin controller and templates
- plugin support for entity actions
- changed column mail to email in customer table
- refactored theme events
This commit is contained in:
Kevin Papst
2019-03-11 14:46:30 +01:00
committed by GitHub
parent 519be2d5a2
commit 3ac72a5c89
104 changed files with 1878 additions and 976 deletions

View File

@@ -137,7 +137,20 @@ abstract class ControllerBaseTest extends WebTestCase
$client->getResponse()->isSuccessful(),
sprintf('The secure URL %s is not protected for role %s', $url, $role)
);
$this->assertContains('Symfony\Component\Security\Core\Exception\AccessDeniedException', $client->getResponse()->getContent());
$this->assertAccessDenied($client);
}
protected function assertAccessDenied(Client $client)
{
$this->assertFalse(
$client->getResponse()->isSuccessful(),
'Access is not denied for URL: ' . $client->getRequest()->getUri()
);
$this->assertContains(
'Symfony\Component\Security\Core\Exception\AccessDeniedException',
$client->getResponse()->getContent(),
'Could not find AccessDeniedException in response'
);
}
/**
@@ -231,10 +244,22 @@ abstract class ControllerBaseTest extends WebTestCase
}
}
/**
* @param Client $client
*/
protected function assertHasNoEntriesWithFilter(Client $client)
{
$this->assertCalloutWidgetWithMessage($client, 'No entries were found based on your selected filters.');
}
/**
* @param Client $client
* @param string $message
*/
protected function assertCalloutWidgetWithMessage(Client $client, string $message)
{
$node = $client->getCrawler()->filter('div.callout.callout-warning.lead');
$this->assertContains('No entries were found based on your selected filters.', $node->text());
$this->assertContains($message, $node->text());
}
/**