You are here

public function StroopwafelTest::testAccessors in Bakery Single Sign-On System 8.2

@covers ::getUid @covers ::getData @dataProvider provideTestData

File

tests/src/Unit/Cookies/StroopwafelTest.php, line 37

Class

StroopwafelTest
@coversDefaultClass \Drupal\bakery\Cookies\Stroopwafel

Namespace

Drupal\Tests\bakery\Unit\Cookies

Code

public function testAccessors($data) {
  $cookie = Stroopwafel::fromData($data);
  $this
    ->assertEquals($data['uid'], $cookie
    ->getUid());
  $this
    ->assertEquals(unserialize($data['data']), $cookie
    ->getData());
}