diff options
author | Angie Byron <webchick@24967.no-reply.drupal.org> | 2008-09-06 15:06:10 +0000 |
---|---|---|
committer | Angie Byron <webchick@24967.no-reply.drupal.org> | 2008-09-06 15:06:10 +0000 |
commit | 73356fde8b3ebd076e2c588bb8935f914fd8ebb8 (patch) | |
tree | f417468dde71b29eecc2763a5c60eceab13685ae /modules/simpletest/tests | |
parent | e5b0e5f76c0695a01d13c55147a8287df8750594 (diff) | |
download | brdo-73356fde8b3ebd076e2c588bb8935f914fd8ebb8.tar.gz brdo-73356fde8b3ebd076e2c588bb8935f914fd8ebb8.tar.bz2 |
#296310 by DamZ: Fixes to drupal_http_request() and accompanying tests.
Diffstat (limited to 'modules/simpletest/tests')
-rw-r--r-- | modules/simpletest/tests/common.test | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/modules/simpletest/tests/common.test b/modules/simpletest/tests/common.test index 25c15ab1e..176cc3502 100644 --- a/modules/simpletest/tests/common.test +++ b/modules/simpletest/tests/common.test @@ -168,7 +168,7 @@ class DrupalHTTPRequestTestCase extends DrupalWebTestCase { function testDrupalHTTPRequestRedirect() { $redirect_301 = drupal_http_request(url('system-test/redirect/301', array('absolute' => TRUE)), array(), 'GET', NULL, 1); - $this->assertEqual($redirect_301->redirect_code, 200, t('drupal_http_request follows the 301 redirect.')); + $this->assertEqual($redirect_301->redirect_code, 301, t('drupal_http_request follows the 301 redirect.')); $redirect_301 = drupal_http_request(url('system-test/redirect/301', array('absolute' => TRUE)), array(), 'GET', NULL, 0); $this->assertFalse(isset($redirect_301->redirect_code), t('drupal_http_request does not follow 301 redirect if $retry = 0.')); @@ -183,13 +183,13 @@ class DrupalHTTPRequestTestCase extends DrupalWebTestCase { $this->assertEqual($redirect_invalid->error, 'invalid schema ftp', t('301 redirect to invalid URL returned with error "!error".', array('!error' => $redirect_invalid->error))); $redirect_302 = drupal_http_request(url('system-test/redirect/302', array('absolute' => TRUE)), array(), 'GET', NULL, 1); - $this->assertEqual($redirect_302->redirect_code, 200, t('drupal_http_request follows the 302 redirect.')); + $this->assertEqual($redirect_302->redirect_code, 302, t('drupal_http_request follows the 302 redirect.')); $redirect_302 = drupal_http_request(url('system-test/redirect/302', array('absolute' => TRUE)), array(), 'GET', NULL, 0); $this->assertFalse(isset($redirect_302->redirect_code), t('drupal_http_request does not follow 302 redirect if $retry = 0.')); $redirect_307 = drupal_http_request(url('system-test/redirect/307', array('absolute' => TRUE)), array(), 'GET', NULL, 1); - $this->assertEqual($redirect_307->redirect_code, 200, t('drupal_http_request follows the 307 redirect.')); + $this->assertEqual($redirect_307->redirect_code, 307, t('drupal_http_request follows the 307 redirect.')); $redirect_307 = drupal_http_request(url('system-test/redirect/307', array('absolute' => TRUE)), array(), 'GET', NULL, 0); $this->assertFalse(isset($redirect_307->redirect_code), t('drupal_http_request does not follow 307 redirect if $retry = 0.')); |