You are here

public function EnsureEventTest::test in Flysystem 8

Same name and namespace in other branches
  1. 3.x tests/src/Unit/Event/EnsureEventTest.php \Drupal\Tests\flysystem\Unit\Event\EnsureEventTest::test()
  2. 2.0.x tests/src/Unit/Event/EnsureEventTest.php \Drupal\Tests\flysystem\Unit\Event\EnsureEventTest::test()
  3. 3.0.x tests/src/Unit/Event/EnsureEventTest.php \Drupal\Tests\flysystem\Unit\Event\EnsureEventTest::test()

Tests the basic setters/getters of EnsureEvent.

File

tests/src/Unit/Event/EnsureEventTest.php, line 20

Class

EnsureEventTest
Tests EnsureEvent.

Namespace

Drupal\Tests\flysystem\Unit\Event

Code

public function test() {
  $event = new EnsureEvent('scheme', 10, 'message', array(
    '1234',
  ));
  $this
    ->assertSame('scheme', $event
    ->getScheme());
  $this
    ->assertSame(10, $event
    ->getSeverity());
  $this
    ->assertSame('message', $event
    ->getMessage());
  $this
    ->assertSame(array(
    '1234',
  ), $event
    ->getContext());
}