3 namespace Drupal\Tests\Component\Serialization;
6 * Provides standard data to validate different YAML implementations.
8 abstract class YamlTestBase extends \PHPUnit_Framework_TestCase {
11 * Some data that should be able to be serialized.
13 public function providerEncodeDecodeTests() {
18 'ponies' => ['nope', 'thanks'],
30 'how_many_times' => 123,
31 'should_i_ask' => FALSE,
43 * Some data that should be able to be de-serialized.
45 public function providerDecodeTests() {
56 version: &jquery_ui 1.10.2
63 'version' => '1.10.2',
65 'jquery.ui.accordion' => [
66 'version' => '1.10.2',
73 foreach ($this->providerBoolTest() as $test) {
74 $data[] = ['bool: ' . $test[0], ['bool' => $test[1]]];
76 $data = array_merge($data, $this->providerBoolTest());
82 * Tests different boolean serialization and de-serialization.
84 public function providerBoolTest() {