You are here

public function SecKitTestCase::testXXSSProtectionIs1 in Security Kit 7

Same name and namespace in other branches
  1. 6 seckit.test \SecKitTestCase::testXXSSProtectionIs1()

Tests set to 1 X-XSS-Protection HTTP response header.

File

./seckit.test, line 361
Tests for Security Kit module.

Class

SecKitTestCase
Functional tests for Security Kit.

Code

public function testXXSSProtectionIs1() {
  $form['seckit_xss[x_xss][select]'] = SECKIT_X_XSS_1;
  $this
    ->drupalPost('admin/config/system/seckit', $form, t('Save configuration'));
  $this
    ->assertEqual('1', $this
    ->drupalGetHeader('X-XSS-Protection'), t('X-XSS-Protection is set to 1.'));
}