private function SecuritytxtModuleEnabledTestCase::setConfigurationViaDatabase in Security.txt 7
Set configuration via direct database access.
1 call to SecuritytxtModuleEnabledTestCase::setConfigurationViaDatabase()
- SecuritytxtModuleEnabledTestCase::testPageAccess in ./
securitytxt.test - Test page access for various users.
File
- ./
securitytxt.test, line 370 - Tests for securitytxt.module.
Class
- SecuritytxtModuleEnabledTestCase
- Test case with the Security.txt module enabled.
Code
private function setConfigurationViaDatabase($enabled, $contact_email, $contact_phone, $contact_url, $encryption_key_url, $policy_url, $acknowledgement_url, $signature_text) {
$settings = array();
$settings['enabled'] = $enabled;
$settings['contact_email'] = $contact_email;
$settings['contact_phone'] = $contact_phone;
$settings['contact_url'] = $contact_url;
$settings['encryption_key_url'] = $encryption_key_url;
$settings['policy_url'] = $policy_url;
$settings['acknowledgement_url'] = $acknowledgement_url;
$settings['signature_text'] = $signature_text;
variable_set('securitytxt', $settings);
}