Linux polon 4.19.0-27-amd64 #1 SMP Debian 4.19.316-1 (2024-06-25) x86_64
Apache/2.4.59 (Debian)
: 10.2.73.233 | : 18.116.49.143
Cant Read [ /etc/named.conf ]
5.6.40-64+0~20230107.71+debian10~1.gbp673146
www-data
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
CREATE WP USER
README
+ Create Folder
+ Create File
/
home /
baltic /
web /
modules /
color /
[ HOME SHELL ]
Name
Size
Permission
Action
images
[ DIR ]
drwxr-xr-x
color-rtl.css
718
B
-rw-r--r--
color.css
1.41
KB
-rw-r--r--
color.info
291
B
-rw-r--r--
color.install
2.23
KB
-rw-r--r--
color.js
7.44
KB
-rw-r--r--
color.module
26.94
KB
-rw-r--r--
color.test
4.18
KB
-rw-r--r--
preview.html
562
B
-rw-r--r--
preview.js
1.43
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : color.test
<?php /** * @file * Tests for color module. */ /** * Tests the Color module functionality. */ class ColorTestCase extends DrupalWebTestCase { protected $big_user; protected $themes; protected $colorTests; public static function getInfo() { return array( 'name' => 'Color functionality', 'description' => 'Modify the Bartik and Garland theme colors and make sure the changes are reflected on the frontend', 'group' => 'Color', ); } function setUp() { parent::setUp('color'); // Create users. $this->big_user = $this->drupalCreateUser(array('administer themes')); // This tests the color module in both Bartik and Garland. $this->themes = array( 'bartik' => array( 'palette_input' => 'palette[bg]', 'scheme' => 'slate', 'scheme_color' => '#3b3b3b', ), 'garland' => array( 'palette_input' => 'palette[link]', 'scheme' => 'greenbeam', 'scheme_color' => '#0c7a00', ), ); theme_enable(array_keys($this->themes)); // Array filled with valid and not valid color values $this->colorTests = array( '#000' => TRUE, '#123456' => TRUE, '#abcdef' => TRUE, '#0' => FALSE, '#00' => FALSE, '#0000' => FALSE, '#00000' => FALSE, '123456' => FALSE, '#00000g' => FALSE, ); } /** * Tests the Color module functionality. */ function testColor() { foreach ($this->themes as $theme => $test_values) { $this->_testColor($theme, $test_values); } } /** * Tests the Color module functionality using the given theme. */ function _testColor($theme, $test_values) { variable_set('theme_default', $theme); $settings_path = 'admin/appearance/settings/' . $theme; $this->drupalLogin($this->big_user); $this->drupalGet($settings_path); $this->assertResponse(200); $edit['scheme'] = ''; $edit[$test_values['palette_input']] = '#123456'; $this->drupalPost($settings_path, $edit, t('Save configuration')); $this->drupalGet('<front>'); $stylesheets = variable_get('color_' . $theme . '_stylesheets', array()); $this->assertPattern('|' . file_create_url($stylesheets[0]) . '|', 'Make sure the color stylesheet is included in the content. (' . $theme . ')'); $stylesheet_content = join("\n", file($stylesheets[0])); $this->assertTrue(strpos($stylesheet_content, 'color: #123456') !== FALSE, 'Make sure the color we changed is in the color stylesheet. (' . $theme . ')'); $this->drupalGet($settings_path); $this->assertResponse(200); $edit['scheme'] = $test_values['scheme']; $this->drupalPost($settings_path, $edit, t('Save configuration')); $this->drupalGet('<front>'); $stylesheets = variable_get('color_' . $theme . '_stylesheets', array()); $stylesheet_content = join("\n", file($stylesheets[0])); $this->assertTrue(strpos($stylesheet_content, 'color: ' . $test_values['scheme_color']) !== FALSE, 'Make sure the color we changed is in the color stylesheet. (' . $theme . ')'); // Test with aggregated CSS turned on. variable_set('preprocess_css', 1); $this->drupalGet('<front>'); $stylesheets = variable_get('drupal_css_cache_files', array()); $stylesheet_content = ''; foreach ($stylesheets as $key => $uri) { $stylesheet_content .= join("\n", file(drupal_realpath($uri))); } $this->assertTrue(strpos($stylesheet_content, 'public://') === FALSE, 'Make sure the color paths have been translated to local paths. (' . $theme . ')'); variable_set('preprocess_css', 0); } /** * Tests whether the provided color is valid. */ function testValidColor() { variable_set('theme_default', 'bartik'); $settings_path = 'admin/appearance/settings/bartik'; $this->drupalLogin($this->big_user); $edit['scheme'] = ''; foreach ($this->colorTests as $color => $is_valid) { $edit['palette[bg]'] = $color; $this->drupalPost($settings_path, $edit, t('Save configuration')); if($is_valid) { $this->assertText('The configuration options have been saved.'); } else { $this->assertText('Main background must be a valid hexadecimal CSS color value.'); } } } }
Close