setupFile = dirname( __FILE__ ) . '/../PortableInfobox.setup.php'; parent::setUp(); } /** * @dataProvider testIsEmptyDataProvider */ public function testIsEmpty( $string, $expectedOutput ) { $xml = simplexml_load_string( $string ); $node = new Wikia\PortableInfobox\Parser\Nodes\NodeFooter( $xml, [] ); $data = $node->getData(); $this->assertTrue( $node->isEmpty( $data ) == $expectedOutput ); } public function testIsEmptyDataProvider() { return [ [ 'string' => '', 'expectedOutput' => false ], [ 'string' => '', 'expectedOutput' => false ], [ 'string' => '', 'expectedOutput' => false ], [ 'string' => '', 'expectedOutput' => false ], [ 'string' => '', 'expectedOutput' => true ], [ 'string' => '', 'expectedOutput' => true ] ]; } }