public function RequiredByRoleCommonWebTestCase::DotestChangeToRequiredByRole in Required by role 7.2
Same name and namespace in other branches
- 7 tests/required_by_role_test/RequiredByRoleCommonWebTestCase.test \RequiredByRoleCommonWebTestCase::DotestChangeToRequiredByRole()
Test changing the required property to required by role.
1 call to RequiredByRoleCommonWebTestCase::DotestChangeToRequiredByRole()
- RequiredByRoleCommonWebTestCase::testCommonBehaviors in tests/
required_by_role_test/ RequiredByRoleCommonWebTestCase.test - Group the tests for better performance.
File
- tests/
required_by_role_test/ RequiredByRoleCommonWebTestCase.test, line 222 - Tests for the common cases.
Class
- RequiredByRoleCommonWebTestCase
- @file Tests for the common cases.
Code
public function DotestChangeToRequiredByRole() {
$rid = (int) $this->required_fields_rid;
$settings = array(
"instance[settings][required_plugin]" => "by_role",
"instance[settings][required_plugin_options][{$rid}]" => $rid,
);
$this
->setFieldRequiredProperty($settings);
$ids = array(
'edit-instance-settings-required-plugin-by-role' => 'by_role',
'edit-instance-settings-required-plugin-options-' . $rid => $rid,
);
$this
->checkFieldRequiredProperty($ids);
}