mirror of
https://github.com/tag1consulting/d7_to_d10_migration.git
synced 2025-09-06 09:01:23 +00:00
Initial commit
This commit is contained in:
commit
c5e731d8ae
2773 changed files with 600767 additions and 0 deletions
44
drupal7/web/modules/syslog/syslog.test
Normal file
44
drupal7/web/modules/syslog/syslog.test
Normal file
|
@ -0,0 +1,44 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Tests for syslog.module.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Tests the Syslog module functionality.
|
||||
*/
|
||||
class SyslogTestCase extends DrupalWebTestCase {
|
||||
public static function getInfo() {
|
||||
return array(
|
||||
'name' => 'Syslog functionality',
|
||||
'description' => 'Test syslog settings.',
|
||||
'group' => 'Syslog'
|
||||
);
|
||||
}
|
||||
|
||||
function setUp() {
|
||||
parent::setUp('syslog');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests the syslog settings page.
|
||||
*/
|
||||
function testSettings() {
|
||||
$admin_user = $this->drupalCreateUser(array('administer site configuration'));
|
||||
$this->drupalLogin($admin_user);
|
||||
|
||||
$edit = array();
|
||||
// If we're on Windows, there is no configuration form.
|
||||
if (defined('LOG_LOCAL6')) {
|
||||
$this->drupalPost('admin/config/development/logging', array('syslog_facility' => LOG_LOCAL6), t('Save configuration'));
|
||||
$this->assertText(t('The configuration options have been saved.'));
|
||||
|
||||
$this->drupalGet('admin/config/development/logging');
|
||||
if ($this->parse()) {
|
||||
$field = $this->xpath('//option[@value=:value]', array(':value' => LOG_LOCAL6)); // Should be one field.
|
||||
$this->assertTrue($field[0]['selected'] == 'selected', 'Facility value saved.');
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue