You are here

public function EncodeTest::testSerializeArray in Tamper 8

Test serialize.

File

tests/src/Unit/Plugin/Tamper/EncodeTest.php, line 27

Class

EncodeTest
Tests the encode / decode plugin.

Namespace

Drupal\Tests\tamper\Unit\Plugin\Tamper

Code

public function testSerializeArray() {
  $config = [
    Encode::SETTING_MODE => 'serialize',
  ];
  $plugin = new Encode($config, 'encode', [], $this
    ->getMockSourceDefinition());
  $this
    ->assertEquals('a:0:{}', $plugin
    ->tamper([]));
}