function FlexsliderTestCase::testOptionSet in Flex Slider 7
File
- ./flexslider.test, line 51
- Test cases for Flex Slider
Class
- FlexsliderTestCase
- @file
Test cases for Flex Slider
Code
function testOptionSet() {
$this
->drupalLogin($this->admin_user);
$this
->drupalGet('admin/config/media/flexslider/add');
$this
->assertResponse(200, t('Administrative user can reach the "Add" form.'));
$optionset = array();
$optionset['title'] = 'testset';
$optionset['name'] = 'testset';
$this
->drupalPost('admin/config/media/flexslider/add', $optionset, t('Create new option set'));
$this
->assertResponse(200);
$this
->assertText('Option set testset was created.', t('Successfully saved the new optionset "testset"'));
$options = _flexslider_test_options();
foreach ($options['valid'] as $testset) {
$this
->drupalPost('admin/config/media/flexslider/edit/default', $testset, t('Save option set'));
$thid
->assertResponse(200);
}
}