diff --git a/core/modules/openid/lib/Drupal/openid/Tests/OpenIDFunctionalTest.php b/core/modules/openid/lib/Drupal/openid/Tests/OpenIDFunctionalTest.php
index b0c940e9e972e163366620b5a8f03795a00d8512..71c6f0291da0a95dbaabf67427b7cab4b13ec7bf 100644
--- a/core/modules/openid/lib/Drupal/openid/Tests/OpenIDFunctionalTest.php
+++ b/core/modules/openid/lib/Drupal/openid/Tests/OpenIDFunctionalTest.php
@@ -356,6 +356,7 @@ function addRedirectedIdentity($identity, $version = 2, $local_id = 'http://exam
    * Tests that openid.signed is verified.
    */
   function testSignatureValidation() {
+    module_load_include('inc', 'openid');
     // Use a User-supplied Identity that is the URL of an XRDS document.
     $identity = url('openid-test/yadis/xrds', array('absolute' => TRUE));
 
@@ -372,7 +373,7 @@ function testSignatureValidation() {
     // Sign all mandatory fields and a custom field.
     $keys_to_sign = array('op_endpoint', 'claimed_id', 'identity', 'return_to', 'response_nonce', 'assoc_handle', 'foo');
     $association = new stdClass();
-    $association->mac_key = variable_get('mac_key');
+    $association->mac_key = NULL;
     $response = array(
       'openid.op_endpoint' => url('openid-test/endpoint', array('absolute' => TRUE)),
       'openid.claimed_id' => $identity,
diff --git a/core/modules/openid/tests/openid_test.install b/core/modules/openid/tests/openid_test.install
deleted file mode 100644
index 3bd4978f1a2eeeb0da9331fdeebfb0dc94744abe..0000000000000000000000000000000000000000
--- a/core/modules/openid/tests/openid_test.install
+++ /dev/null
@@ -1,17 +0,0 @@
-<?php
-
-/**
- * @file
- * Install, update and uninstall functions for the openid_test module.
- */
-
-/**
- * Implements hook_install().
- */
-function openid_test_install() {
-  module_load_include('inc', 'openid');
-  // Generate a MAC key (Message Authentication Code) used for signing messages.
-  // The variable is base64-encoded, because variables cannot contain non-UTF-8
-  // data.
-  variable_set('openid_test_mac_key', base64_encode(_openid_get_bytes(20)));
-}
diff --git a/core/modules/openid/tests/openid_test.module b/core/modules/openid/tests/openid_test.module
index 719d48c6c57cc7d308a247e534337cf35bb53df6..5fe64cf10898a7be22621e0b69a0f76413cbb654 100644
--- a/core/modules/openid/tests/openid_test.module
+++ b/core/modules/openid/tests/openid_test.module
@@ -271,7 +271,7 @@ function _openid_test_endpoint_associate() {
   $shared = _openid_math_powmod($cpub, $private, $mod);
 
   // Encrypt the MAC key using the shared secret.
-  $enc_mac_key = base64_encode(_openid_dh_xorsecret($shared, base64_decode(variable_get('mac_key'))));
+  $enc_mac_key = base64_encode(_openid_dh_xorsecret($shared, NULL));
 
   // Generate response including our public key and the MAC key. Using our
   // public key and its own private key, the Relying Party can calculate the
@@ -343,7 +343,7 @@ function _openid_test_endpoint_authenticate() {
 
   // Sign the message using the MAC key that was exchanged during association.
   $association = new stdClass();
-  $association->mac_key = variable_get('mac_key');
+  $association->mac_key = NULL;
   if (!isset($response['openid.sig'])) {
     $response['openid.sig'] = _openid_signature($association, $response, $keys_to_sign);
   }