コード例 #1
0
ファイル: GeneratorTest.php プロジェクト: georgeh/php-beerxml
 public function testOnlyAssignsConditionalFieldsIfNotEmpty()
 {
     $recipe = new Recipe();
     $recipe->setAsstBrewer('Bruce Wayne');
     $this->generator->addRecord($recipe);
     $xml = $this->generator->render();
     $this->assertContains('<ASST_BREWER>Bruce Wayne</ASST_BREWER>', $xml);
     $this->assertNotContains('<TERTIARY_AGE>', $xml);
 }