コード例 #1
0
 public function testInvalidInput()
 {
     $content = file_get_contents(__DIR__ . '/Resources/invalid.html');
     $document = FrontMatter::parse($content);
     $this->assertEquals(array(), $document->getConfig());
     $this->assertEquals($content, $document->getContent());
 }
コード例 #2
0
ファイル: Confgen.php プロジェクト: clue/confgen
 private function extractFrontMatter($file)
 {
     $contents = $this->fs->fileContents($file);
     return FrontMatter::parse($contents);
 }