From 813849e5216cb87121e0f778a734575be6a36052 Mon Sep 17 00:00:00 2001 From: ArthurHoaro Date: Sun, 7 May 2017 16:50:20 +0200 Subject: Add history entries for API endpoint CHANGED: datetime is now store as an object in history store file --- tests/NetscapeBookmarkUtils/BookmarkImportTest.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'tests/NetscapeBookmarkUtils') diff --git a/tests/NetscapeBookmarkUtils/BookmarkImportTest.php b/tests/NetscapeBookmarkUtils/BookmarkImportTest.php index f838f259..5fc1d1e8 100644 --- a/tests/NetscapeBookmarkUtils/BookmarkImportTest.php +++ b/tests/NetscapeBookmarkUtils/BookmarkImportTest.php @@ -628,7 +628,7 @@ class BookmarkImportTest extends PHPUnit_Framework_TestCase $this->assertEquals($nbLinks, count($history)); foreach ($history as $value) { $this->assertEquals(History::CREATED, $value['event']); - $this->assertTrue(new DateTime('-5 seconds') < DateTime::createFromFormat(DateTime::ATOM, $value['datetime'])); + $this->assertTrue(new DateTime('-5 seconds') < $value['datetime']); $this->assertTrue(is_int($value['id'])); } @@ -638,7 +638,7 @@ class BookmarkImportTest extends PHPUnit_Framework_TestCase $this->assertEquals($nbLinks * 2, count($history)); for ($i = 0 ; $i < $nbLinks ; $i++) { $this->assertEquals(History::UPDATED, $history[$i]['event']); - $this->assertTrue(new DateTime('-5 seconds') < DateTime::createFromFormat(DateTime::ATOM, $history[$i]['datetime'])); + $this->assertTrue(new DateTime('-5 seconds') < $history[$i]['datetime']); $this->assertTrue(is_int($history[$i]['id'])); } } -- cgit v1.2.3