Class CookieWrapperTest.
More...
◆ setUp()
ILIAS\HTTP\Cookies\CookieWrapperTest::setUp |
( |
| ) |
|
|
protected |
Definition at line 44 of file CookieWrapperTest.php.
49 $cookieName =
"ilias";
50 $cookieValue =
"theNewCookiesAreYummy";
51 $this->cookie = self::$cookieFactory->create($cookieName, $cookieValue);
◆ setUpBeforeClass()
static ILIAS\HTTP\Cookies\CookieWrapperTest::setUpBeforeClass |
( |
| ) |
|
|
static |
Definition at line 37 of file CookieWrapperTest.php.
39 parent::setUpBeforeClass();
40 self::$cookieFactory =
new CookieFactoryImpl();
◆ testExpireDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testExpireDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 95 of file CookieWrapperTest.php.
97 $newCookie = $this->cookie->expire();
100 $this->assertNotEquals($this->cookie->getExpires(), $newCookie->getExpires());
◆ testRememberForeverDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testRememberForeverDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 83 of file CookieWrapperTest.php.
85 $newCookie = $this->cookie->rememberForLongTime();
88 $this->assertNotEquals($this->cookie->getExpires(), $newCookie->getExpires());
◆ testWithDomainDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithDomainDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 133 of file CookieWrapperTest.php.
135 $domain =
'ilias.de';
136 $newCookie = $this->cookie->withDomain($domain);
138 $this->assertEquals($domain, $newCookie->getDomain());
139 $this->assertNotEquals($this->cookie->getDomain(), $newCookie->getDomain());
◆ testWithExpiresDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithExpiresDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 70 of file CookieWrapperTest.php.
73 $newCookie = $this->cookie->withExpires($expires);
75 $this->assertEquals($expires, $newCookie->getExpires());
76 $this->assertNotEquals($this->cookie->getExpires(), $newCookie->getExpires());
◆ testWithHttpOnlyDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithHttpOnlyDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 159 of file CookieWrapperTest.php.
162 $newCookie = $this->cookie->withHttpOnly($httpOnly);
164 $this->assertTrue($newCookie->getHttpOnly());
165 $this->assertNotEquals($this->cookie->getHttpOnly(), $newCookie->getHttpOnly());
◆ testWithMaxAgeDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithMaxAgeDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 107 of file CookieWrapperTest.php.
110 $newCookie = $this->cookie->withMaxAge($maxAge);
112 $this->assertEquals($maxAge, $newCookie->getMaxAge());
113 $this->assertNotEquals($this->cookie->getMaxAge(), $newCookie->getMaxAge());
◆ testWithPathDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithPathDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 120 of file CookieWrapperTest.php.
123 $newCookie = $this->cookie->withPath($path);
125 $this->assertEquals($path, $newCookie->getPath());
126 $this->assertNotEquals($this->cookie->getPath(), $newCookie->getPath());
◆ testWithSecureDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithSecureDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 146 of file CookieWrapperTest.php.
149 $newCookie = $this->cookie->withSecure($secure);
151 $this->assertTrue($newCookie->getSecure());
152 $this->assertNotEquals($this->cookie->getSecure(), $newCookie->getSecure());
◆ testWithValueDoesNotChangeTheCurrentObject()
ILIAS\HTTP\Cookies\CookieWrapperTest::testWithValueDoesNotChangeTheCurrentObject |
( |
| ) |
|
Definition at line 58 of file CookieWrapperTest.php.
61 $newCookie = $this->cookie->withValue(
"yes!");
62 $this->assertEquals($newValue, $newCookie->getValue());
63 $this->assertNotEquals($this->cookie->getValue(), $newCookie->getValue());
◆ $cookie
◆ $cookieFactory
CookieFactory ILIAS\HTTP\Cookies\CookieWrapperTest::$cookieFactory |
|
staticprivate |
The documentation for this class was generated from the following file: