summaryrefslogtreecommitdiff
path: root/test/storage/http_header_parsing.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'test/storage/http_header_parsing.cpp')
-rw-r--r--test/storage/http_header_parsing.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/storage/http_header_parsing.cpp b/test/storage/http_header_parsing.cpp
index 14bd99bdb3..827aa70abc 100644
--- a/test/storage/http_header_parsing.cpp
+++ b/test/storage/http_header_parsing.cpp
@@ -21,9 +21,9 @@ TEST_F(Storage, HTTPExpiresParsing) {
EXPECT_EQ(nullptr, res.error);
ASSERT_TRUE(res.data.get());
EXPECT_EQ("Hello World!", *res.data);
- EXPECT_EQ(1420797926, res.expires.count());
- EXPECT_EQ(1420794326, res.modified.count());
- EXPECT_EQ("foo", res.etag);
+ EXPECT_EQ(SystemClock::from_time_t(1420797926), res.expires);
+ EXPECT_EQ(SystemClock::from_time_t(1420794326), res.modified);
+ EXPECT_EQ("foo", *res.etag);
loop.stop();
HTTPExpiresTest.finish();
});
@@ -47,9 +47,9 @@ TEST_F(Storage, HTTPCacheControlParsing) {
EXPECT_EQ(nullptr, res.error);
ASSERT_TRUE(res.data.get());
EXPECT_EQ("Hello World!", *res.data);
- EXPECT_GT(2, std::abs(res.expires.count() - now.count() - 120)) << "Expiration date isn't about 120 seconds in the future";
- EXPECT_EQ(Seconds::zero(), res.modified);
- EXPECT_EQ("", res.etag);
+ EXPECT_GT(2, std::abs(toSeconds(*res.expires).count() - now.count() - 120)) << "Expiration date isn't about 120 seconds in the future";
+ EXPECT_FALSE(bool(res.modified));
+ EXPECT_FALSE(bool(res.etag));
loop.stop();
HTTPCacheControlTest.finish();
});