WARNING! You can only run this test off of a "real" webserver (i.e. over http); you can't run this test directly off of the file system.
Also note that the paths used in this test don't have to actually exist; we can get 404 errors on every one of these pages but still successfully test the cookie functionality.
Test Cookie |
||
open | /path1/cookies | |
deleteCookie | testCookieWithSameName | / |
deleteCookie | addedCookieForPath1 | /path1/ |
verifyCookie | ||
open | /path2/cookies | |
deleteCookie | testCookieWithSameName | /path2/ |
deleteCookie | addedCookieForPath2 | /path2/ |
verifyCookie |
open | /path1/cookies | |
createCookie | addedCookieForPath1=new value1 | |
createCookie | addedCookieForPath2=new value2 | path=/path2/, max_age=60 |
open | /path1/cookies | |
verifyCookie | regex:addedCookieForPath1=new value1 | |
verifyNotCookie | regex:testCookie | |
verifyNotCookie | regex:addedCookieForPath2 | |
deleteCookie | addedCookieForPath1 | /path1/ |
verifyCookie | ||
open | /path2/cookies | |
verifyCookie | addedCookieForPath2=new value2 | |
verifyNotCookie | regex:addedCookieForPath1 | |
deleteCookie | addedCookieForPath2 | /path2/ |
verifyCookie |
createCookie | testCookieWithSameName=new value1 | path=/ |
createCookie | testCookieWithSameName=new value2 | path=/path2/ |
open | /path1/cookies | |
verifyCookie | testCookieWithSameName=new value1 | |
open | /path2/cookies | |
verifyCookie | regex:testCookieWithSameName=new value1 | |
verifyCookie | regex:testCookieWithSameName=new value2 | |
deleteCookie | testCookieWithSameName | /path2/ |
open | /path2/cookies | |
verifyCookie | testCookieWithSameName=new value1 | |
verifyNotCookie | regex:testCookieWithSameName=new value2 |