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

Unified Diff: base/test/simple_test_tick_clock.h

Issue 1178423008: Provision to start base::SimpleTestTickClock at initial ticks Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removed the default ctor for SimpleTestTickClock. Created 5 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 | « no previous file | base/test/simple_test_tick_clock.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/test/simple_test_tick_clock.h
diff --git a/base/test/simple_test_tick_clock.h b/base/test/simple_test_tick_clock.h
index aebdebcbcf54e7016a1629b5405eb40cbf22d801..629ced9f7841408e6eaffbeffd9f50ae4d15f3b8 100644
--- a/base/test/simple_test_tick_clock.h
+++ b/base/test/simple_test_tick_clock.h
@@ -17,8 +17,9 @@ namespace base {
// called from any thread.
class SimpleTestTickClock : public TickClock {
public:
- // Starts off with a clock set to TimeTicks().
- SimpleTestTickClock();
+ // Start off with a clock set to some initial tick(s)
+ // Avoids having to Advance(initial) for tests
+ SimpleTestTickClock(TimeTicks initial = TimeTicks());
Paweł Hajdan Jr. 2015/06/30 11:40:19 Default arguments are prohibited, please see https
Ankur Verma 2015/06/30 11:58:39 Quoting from the above documentation: "In addition
Paweł Hajdan Jr. 2015/07/15 17:36:59 Ah, you're right, I didn't notice this. Sorry.
~SimpleTestTickClock() override;
TimeTicks NowTicks() override;
« no previous file with comments | « no previous file | base/test/simple_test_tick_clock.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698