public function BlazyBreakpointTest::testWidthFromDescriptors in Blazy 7
Test widthFromDescriptors.
@covers \Drupal\blazy\BlazyBreakpoint::widthFromDescriptors @dataProvider providerTestWidthFromDescriptors
File
- tests/
BlazyBreakpoint.test, line 49
Class
- BlazyBreakpointTest
- Tests the Blazy breakpoints.
Code
public function testWidthFromDescriptors() {
// Simpletest doesn't support annotation nor @dataProvider, let's loop.
foreach ($this
->providerTestWidthFromDescriptors() as $data) {
$result = BlazyBreakpoint::widthFromDescriptors($data[0]);
$this
->assertEqual($result, $data[1], t('@result returned from input @input', [
'@result' => is_bool($result) ? 'FALSE' : $result,
'@input' => $data[0],
]));
}
}