Skip to content

Commit 0943537

Browse files
committed
Updated to 1.1.5 version
1 parent e3bc95f commit 0943537

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

tests/CookieTest.php

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ public function setUp()
4949
*/
5050
public function testSetCookie()
5151
{
52-
$this->assertTrue(Cookie::set('cookie_name', 'value', 365));
52+
$this->assertTrue($this->Cookie->set('cookie_name', 'value', 365));
5353
}
5454

5555
/**
@@ -61,9 +61,9 @@ public function testSetCookie()
6161
*/
6262
public function testGetCookie()
6363
{
64-
$_COOKIE[Cookie::$prefix . 'cookie_name'] = 'value';
64+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name'] = 'value';
6565

66-
$this->assertContains(Cookie::get('cookie_name'), 'value');
66+
$this->assertContains($this->Cookie->get('cookie_name'), 'value');
6767
}
6868

6969
/**
@@ -75,12 +75,12 @@ public function testGetCookie()
7575
*/
7676
public function testGetAllCookies()
7777
{
78-
$_COOKIE[Cookie::$prefix . 'cookie_name_one'] = 'value';
79-
$_COOKIE[Cookie::$prefix . 'cookie_name_two'] = 'value';
78+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name_one'] = 'value';
79+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name_two'] = 'value';
8080

8181
$this->assertArrayHasKey(
82-
Cookie::$prefix . 'cookie_name_two',
83-
Cookie::get()
82+
$this->Cookie::$prefix . 'cookie_name_two',
83+
$this->Cookie->get()
8484
);
8585
}
8686

@@ -93,7 +93,7 @@ public function testGetAllCookies()
9393
*/
9494
public function testGetAllCookiesNonExistents()
9595
{
96-
$this->assertFalse(Cookie::get());
96+
$this->assertFalse($this->Cookie->get());
9797
}
9898

9999
/**
@@ -105,9 +105,9 @@ public function testGetAllCookiesNonExistents()
105105
*/
106106
public function testPullCookie()
107107
{
108-
$_COOKIE[Cookie::$prefix . 'cookie_name'] = 'value';
108+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name'] = 'value';
109109

110-
$this->assertContains(Cookie::pull('cookie_name'), 'value');
110+
$this->assertContains($this->Cookie->pull('cookie_name'), 'value');
111111
}
112112

113113
/**
@@ -119,7 +119,7 @@ public function testPullCookie()
119119
*/
120120
public function testPullCookieNonExistent()
121121
{
122-
$this->assertFalse(Cookie::pull('cookie_name'));
122+
$this->assertFalse($this->Cookie->pull('cookie_name'));
123123
}
124124

125125
/**
@@ -131,9 +131,9 @@ public function testPullCookieNonExistent()
131131
*/
132132
public function testDestroyOneCookie()
133133
{
134-
$_COOKIE[Cookie::$prefix . 'cookie_name'] = 'value';
134+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name'] = 'value';
135135

136-
$this->assertTrue(Cookie::destroy('cookie_name'));
136+
$this->assertTrue($this->Cookie->destroy('cookie_name'));
137137
}
138138

139139
/**
@@ -145,7 +145,7 @@ public function testDestroyOneCookie()
145145
*/
146146
public function testDestroyOneCookieNonExistent()
147147
{
148-
$this->assertFalse(Cookie::destroy('cookie_name'));
148+
$this->assertFalse($this->Cookie->destroy('cookie_name'));
149149
}
150150

151151
/**
@@ -157,10 +157,10 @@ public function testDestroyOneCookieNonExistent()
157157
*/
158158
public function testDestroyAllCookies()
159159
{
160-
$_COOKIE[Cookie::$prefix . 'cookie_name_one'] = 'value';
161-
$_COOKIE[Cookie::$prefix . 'cookie_name_two'] = 'value';
160+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name_one'] = 'value';
161+
$_COOKIE[$this->Cookie::$prefix . 'cookie_name_two'] = 'value';
162162

163-
$this->assertTrue(Cookie::destroy());
163+
$this->assertTrue($this->Cookie->destroy());
164164
}
165165

166166
/**
@@ -172,6 +172,6 @@ public function testDestroyAllCookies()
172172
*/
173173
public function testDestroyAllCookiesNonExistents()
174174
{
175-
$this->assertFalse(Cookie::destroy());
175+
$this->assertFalse($this->Cookie->destroy());
176176
}
177177
}

0 commit comments

Comments
 (0)