protected function FileSavedEventTest::fileSaved in Tome 8
Triggers the path placeholder event and returns the updated event.
Parameters
string $path: (optional) The HTML path.
Return value
\Drupal\tome_static\Event\FileSavedEvent The file saved event after it is triggered.
1 call to FileSavedEventTest::fileSaved()
- FileSavedEventTest::testGetPath in modules/
tome_static/ tests/ src/ Kernel/ FileSavedEventTest.php - @covers \Drupal\tome_static\Event\FileSavedEvent::getPath
File
- modules/
tome_static/ tests/ src/ Kernel/ FileSavedEventTest.php, line 40
Class
- FileSavedEventTest
- Tests file saved event class.
Namespace
Drupal\Tests\tome_static\KernelCode
protected function fileSaved($path = '/my-file-path') {
$event = new FileSavedEvent($path);
$this->eventDispatcher
->dispatch($this->eventName, $event);
return $event;
}