Permalink
Browse files

test quoted metadata cookie

  • Loading branch information...
1 parent 7b7dd97 commit 420c0087eecebfa0b4faba9b76dc0a75dafa086c @daaku daaku committed Jul 16, 2012
Showing with 11 additions and 0 deletions.
  1. +11 −0 tests/tests.php
View
@@ -352,6 +352,17 @@ public function testMetadataCookie() {
$this->assertEquals(array($key => $val), $fb->publicGetMetadataCookie());
}
+ public function testQuotedMetadataCookie() {
+ $fb = new FBMetadataCookie(array(
+ 'appId' => self::APP_ID,
+ 'secret' => self::SECRET,
+ ));
+ $key = 'foo';
+ $val = '42';
+ $_COOKIE[$fb->publicGetMetadataCookieName()] = "\"$key=$val\"";
+ $this->assertEquals(array($key => $val), $fb->publicGetMetadataCookie());
+ }
+
public function testAPIForLoggedOutUsers() {
$facebook = new TransientFacebook(array(
'appId' => self::APP_ID,

0 comments on commit 420c008

Please sign in to comment.