diff options
author | John Firebaugh <john.firebaugh@gmail.com> | 2016-01-13 14:32:21 -0800 |
---|---|---|
committer | John Firebaugh <john.firebaugh@gmail.com> | 2016-01-22 18:42:53 -0800 |
commit | a877b9b192fb199b8ec6379551b3fb81e13d673d (patch) | |
tree | 8ad116b7966ece0c3e51da3fca9732ea266e2551 /test | |
parent | 27134df2e40efa14928859bface3de0bc2819072 (diff) | |
download | qtlocation-mapboxgl-a877b9b192fb199b8ec6379551b3fb81e13d673d.tar.gz |
[core] Include prior values of caching headers in Resource
This allows the FileSource interface itself to support revalidation. We could (and probably should) now rewrite HTTPContextBase implementations as FileSource implementations.
Diffstat (limited to 'test')
-rw-r--r-- | test/storage/cache_revalidate.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/test/storage/cache_revalidate.cpp b/test/storage/cache_revalidate.cpp index d46f95801e..10dee80a00 100644 --- a/test/storage/cache_revalidate.cpp +++ b/test/storage/cache_revalidate.cpp @@ -40,8 +40,7 @@ TEST_F(Storage, CacheRevalidateSame) { EXPECT_EQ(nullptr, res2.error); EXPECT_TRUE(res2.notModified); - ASSERT_TRUE(res2.data.get()); - EXPECT_EQ("Response", *res2.data); + ASSERT_FALSE(res2.data.get()); EXPECT_TRUE(bool(res2.expires)); EXPECT_FALSE(bool(res2.modified)); // We're not sending the ETag in the 304 reply, but it should still be there. @@ -92,8 +91,7 @@ TEST_F(Storage, CacheRevalidateModified) { EXPECT_EQ(nullptr, res2.error); EXPECT_TRUE(res2.notModified); - ASSERT_TRUE(res2.data.get()); - EXPECT_EQ("Response", *res2.data); + ASSERT_FALSE(res2.data.get()); EXPECT_TRUE(bool(res2.expires)); EXPECT_EQ(SystemClock::from_time_t(1420070400), *res2.modified); EXPECT_FALSE(res2.etag); |