1 field_ui.test public FieldUIViewModeTestHelper::getActualViewMode($entity_type, $bundle, $view_mode)

File

core/modules/field_ui/tests/field_ui.test, line 918
Tests for field_ui.module.

Class

FieldUIViewModeTestHelper
Helper class for testing display mode functionality.

Code

public function getActualViewMode($entity_type, $bundle, $view_mode) {
  $view_mode_settings = field_view_mode_settings($entity_type, $bundle);
  return (!empty($view_mode_settings[$view_mode]['custom_settings']) ? $view_mode : 'default');
}