Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6215)

Unified Diff: chrome/browser/webdata/keyword_table_unittest.cc

Issue 7232023: Added last_modified field to TemplateURL and database. Updated unit tests, including refactoring ... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/webdata/keyword_table.cc ('k') | chrome/browser/webdata/web_database.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/webdata/keyword_table_unittest.cc
===================================================================
--- chrome/browser/webdata/keyword_table_unittest.cc (revision 90021)
+++ chrome/browser/webdata/keyword_table_unittest.cc (working copy)
@@ -13,6 +13,7 @@
#include "testing/gtest/include/gtest/gtest.h"
using base::Time;
+using base::TimeDelta;
class KeywordTableTest : public testing::Test {
public:
@@ -71,6 +72,8 @@
template_url.set_safe_for_autoreplace(true);
Time created_time = Time::Now();
template_url.set_date_created(created_time);
+ Time last_modified_time = created_time + TimeDelta::FromSeconds(10);
+ template_url.set_last_modified(last_modified_time);
template_url.set_show_in_default_list(true);
template_url.set_originating_url(originating_url);
template_url.set_usage_count(32);
@@ -103,6 +106,9 @@
// The database stores time only at the resolution of a second.
EXPECT_EQ(created_time.ToTimeT(), restored_url->date_created().ToTimeT());
+ EXPECT_EQ(last_modified_time.ToTimeT(),
+ restored_url->last_modified().ToTimeT());
+
EXPECT_TRUE(restored_url->show_in_default_list());
EXPECT_EQ(GetID(&template_url), GetID(restored_url));
Property changes on: chrome\browser\webdata\keyword_table_unittest.cc
___________________________________________________________________
Added: svn:eol-style
+ LF
« no previous file with comments | « chrome/browser/webdata/keyword_table.cc ('k') | chrome/browser/webdata/web_database.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698