You are here

private function ResponsivePreviewDeviceCRUD::checkDevices in Responsive Theme Preview 7

Tests exposed devices in the responsive preview list.

1 call to ResponsivePreviewDeviceCRUD::checkDevices()
ResponsivePreviewDeviceCRUD::testDeviceConfiguration in ./responsive_preview.test

File

./responsive_preview.test, line 94
Tests for responsive_preview.module.

Class

ResponsivePreviewDeviceCRUD
@file Tests for responsive_preview.module.

Code

private function checkDevices($devices = array()) {
  foreach ($devices as $name) {
    $device_button = $this
      ->xpath('//button[@data-responsive-preview-name=:name]', array(
      ':name' => $name,
    ));
    $this
      ->assertTrue(!empty($device_button), format_string('%name device shown by default', array(
      '%name' => $name,
    )));
  }
}