summaryrefslogtreecommitdiff
path: root/_test
diff options
context:
space:
mode:
authorKlap-in <klapinklapin@gmail.com>2013-05-21 21:41:40 +0200
committerKlap-in <klapinklapin@gmail.com>2013-05-21 21:41:40 +0200
commita38a6f25d7e46f47a8f358bb16c766f5b96dae45 (patch)
tree74717d9befd52b61a2f82f8e9dadabd28f763958 /_test
parentd572baf83c5a6d61a7f97aa4d115eba76c5f106c (diff)
downloadrpg-a38a6f25d7e46f47a8f358bb16c766f5b96dae45.tar.gz
rpg-a38a6f25d7e46f47a8f358bb16c766f5b96dae45.tar.bz2
fix some minor typos in fetch_imagetoken.test.php
Diffstat (limited to '_test')
-rw-r--r--_test/tests/lib/exe/fetch_imagetoken.test.php44
1 files changed, 22 insertions, 22 deletions
diff --git a/_test/tests/lib/exe/fetch_imagetoken.test.php b/_test/tests/lib/exe/fetch_imagetoken.test.php
index 9e5b6e4a2..99e642557 100644
--- a/_test/tests/lib/exe/fetch_imagetoken.test.php
+++ b/_test/tests/lib/exe/fetch_imagetoken.test.php
@@ -23,10 +23,10 @@ class fetch_imagetoken_test extends DokuWikiTest {
parent::setUp();
global $conf;
- $conf['sendfile'] = 0;
+ $conf['xsendfile'] = 0;
global $MIME, $EXT, $CACHE, $INPUT; // variables fetch creates in global scope -- should this be in fetch?
- }
+ }
function getUri() {
$w = $this->width ? 'w='.$this->width.'&' : '';
@@ -39,14 +39,14 @@ class fetch_imagetoken_test extends DokuWikiTest {
$request = new TestRequest();
return $request->get(array(),str_replace('{%token%}',$token,$this->getUri()));
}
-
- /**
+
+ /**
* modified image request with valid token
* expect: header with mime-type
* expect: content
* expect: no error response
- */
- function test_valid_token(){
+ */
+ function test_valid_token(){
$valid_token = 'tok='.media_get_token($this->media, $this->width, $this->height).'&';
$response = $this->fetchResponse($valid_token);
$this->assertTrue((bool)$response->getHeader('Content-Type'));
@@ -54,24 +54,24 @@ class fetch_imagetoken_test extends DokuWikiTest {
$status_code = $response->getStatusCode();
$this->assertTrue(is_null($status_code) || (200 == $status_code));
- }
-
- /**
+ }
+
+ /**
* modified image request with invalid token
- * expect: 412 status code
- */
- function test_invalid_token(){
- $invalid_token = 'tok='.media_get_token('junk',200,100).'&';
- $this->assertEquals(412,$this->fetchResponse($invalid_token)->getStatusCode());
- }
-
- /**
- * modified image request with no token
* expect: 412 status code
- */
- function test_missing_token(){
- $no_token = '';
- $this->assertEquals(412,$this->fetchResponse($notoken)->getStatusCode());
+ */
+ function test_invalid_token(){
+ $invalid_token = 'tok='.media_get_token('junk',200,100).'&';
+ $this->assertEquals(412,$this->fetchResponse($invalid_token)->getStatusCode());
+ }
+
+ /**
+ * modified image request with no token
+ * expect: 412 status code
+ */
+ function test_missing_token(){
+ $no_token = '';
+ $this->assertEquals(412,$this->fetchResponse($no_token)->getStatusCode());
}
/**