setupFile = dirname( __FILE__ ) . '/../../PortableInfobox.setup.php';
$this->sanitizer = new NodeImageSanitizer();
parent::setUp();
}
/**
* @param $data
* @param $expected
* @dataProvider testSanitizeDataProvider
*/
function testSanitize( $data, $expected ) {
$this->assertEquals(
$expected,
$this->sanitizer->sanitize( $data )
);
}
function testSanitizeDataProvider() {
return [
[
[ 'caption' => 'Test Title with small tag, span tag and tag' ],
[ 'caption' => 'Test Title with small tag, span tag and tag' ]
],
[
[ 'caption' => '' ],
[ 'caption' => '' ],
]
];
}
}