Ejemplo n.º 1
0
 /**
  * Test loading a Yaml string
  */
 public function testLoad()
 {
     $yaml = Fixtures::getSampleYamlString();
     $this->yamlLoader->expects($this->once())->method('readFrom')->willReturn($yaml);
     $this->assertEquals(YamlParser::parse($yaml), $this->yamlLoader->load($yaml));
 }
Ejemplo n.º 2
0
 /**
  * Test loading a JSON string
  */
 public function testLoad()
 {
     $json = Fixtures::getSampleJsonString();
     $this->jsonLoader->expects($this->once())->method('readFrom')->willReturn($json);
     $this->assertEquals(json_decode($json, true), $this->jsonLoader->load($json));
 }