You are here

function dsPanelViewModesTests::DSPanelChangeLayout in Display Suite 7

Change layout.

Parameters

$view_mode: The name of the view mode.

$old_layout: The name of the old layout.

$new_layout: The name of the new layout.

1 call to dsPanelViewModesTests::DSPanelChangeLayout()
dsPanelViewModesTests::testPanelViewModes in tests/ds.panels.test
Panels view modes tests.

File

tests/ds.panels.test, line 62
Panel view modes tests.

Class

dsPanelViewModesTests
@file Panel view modes tests.

Code

function DSPanelChangeLayout($view_mode, $old_layout, $new_layout) {
  $this
    ->drupalPost('admin/structure/types/manage/article/display/' . $view_mode . $old_layout, array(
    'layout' => $new_layout,
  ), t('Next'));
  $this
    ->drupalPost(NULL, array(), t('Save'), array(), array(), 'panels-change-layout');
  $this
    ->assertText(t('Panel layout has been updated.'));
  $this
    ->assertText(t('Configure settings for the !new_layout layout.', array(
    '!new_layout' => $new_layout,
  )));
}