From da272b5a20bec8d39c6d9cdf2fd5573de99083be Mon Sep 17 00:00:00 2001 From: cweiske Date: Wed, 29 Sep 2010 20:53:57 +0000 Subject: [PATCH] check datetime setting git-svn-id: https://semanticscuttle.svn.sourceforge.net/svnroot/semanticscuttle/trunk@774 b3834d28-1941-0410-a4f8-b48e95affb8f --- tests/Api/PostsAddTest.php | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/Api/PostsAddTest.php b/tests/Api/PostsAddTest.php index cc9a2c9..0769bdd 100644 --- a/tests/Api/PostsAddTest.php +++ b/tests/Api/PostsAddTest.php @@ -132,8 +132,8 @@ TXT; $this->assertEquals($bmDescription, $bm['bDescription']); $this->assertEquals($bmTags, $bm['tags']); $this->assertEquals( - strtotime($bmDatetime), - strtotime($bm['bDatetime']) + gmdate('Y-m-d H:i:s', strtotime($bmDatetime)), + $bm['bDatetime'] ); } @@ -162,6 +162,7 @@ TXT; . '&description=' . urlencode($bmTitle) . '&extended=' . urlencode($bmDescription) . '&tags=' . urlencode(implode(' ', $bmTags)) + . '&dt=' . urlencode($bmDatetime) ); $res = $req->send(); @@ -192,6 +193,10 @@ TXT; $this->assertEquals($bmTitle, $bm['bTitle']); $this->assertEquals($bmDescription, $bm['bDescription']); $this->assertEquals($bmTags, $bm['tags']); + $this->assertEquals( + gmdate('Y-m-d H:i:s', strtotime($bmDatetime)), + $bm['bDatetime'] + ); } }