protected function InstallerTest::drupalGet

This override is necessary because the parent drupalGet() calls t(), which is not available early during installation.

Overrides WebTestBase::drupalGet

2 calls to InstallerTest::drupalGet()

File

drupal/core/modules/system/lib/Drupal/system/Tests/InstallerTest.php, line 131
Contains \Drupal\system\Tests\InstallerTest.

Class

InstallerTest
Allows testing of the interactive installer.

Namespace

Drupal\system\Tests

Code

protected function drupalGet($path, array $options = array(), array $headers = array()) {

  // We are re-using a CURL connection here. If that connection still has
  // certain options set, it might change the GET into a POST. Make sure we
  // clear out previous options.
  $out = $this
    ->curlExec(array(
    CURLOPT_HTTPGET => TRUE,
    CURLOPT_URL => $this
      ->getAbsoluteUrl($path),
    CURLOPT_NOBODY => FALSE,
    CURLOPT_HTTPHEADER => $headers,
  ));
  $this
    ->refreshVariables();

  // Ensure that any changes to variables in the other thread are picked up.
  // Replace original page output with new output from redirected page(s).
  if ($new = $this
    ->checkForMetaRefresh()) {
    $out = $new;
  }
  $this
    ->verbose('GET request to: ' . $path . '<hr />Ending URL: ' . $this
    ->getUrl() . '<hr />' . $out);
  return $out;
}