Chromium Code Reviews| Index: chrome/browser/sync/test/integration/status_change_checker.h |
| diff --git a/chrome/browser/sync/test/integration/status_change_checker.h b/chrome/browser/sync/test/integration/status_change_checker.h |
| index b1611cc86b39881da881f2b63ecfe66235879ded..c26ba5011610d4dbd574ec08ec4ac5117879147e 100644 |
| --- a/chrome/browser/sync/test/integration/status_change_checker.h |
| +++ b/chrome/browser/sync/test/integration/status_change_checker.h |
| @@ -21,18 +21,26 @@ class ProfileSyncServiceHarness; |
| // sense to call StartBlockingWait() more than once. |
| class StatusChangeChecker { |
| public: |
| - explicit StatusChangeChecker(); |
| + StatusChangeChecker(); |
| // Returns a string representing this current StatusChangeChecker, and |
| // possibly some small part of its state. For example: "AwaitPassphraseError" |
| // or "AwaitMigrationDone(BOOKMARKS)". |
| virtual std::string GetDebugMessage() const = 0; |
| + // Returns whether the state the checker is currently in is its desired |
| + // configuration. |
| + virtual bool IsExitConditionSatisfied() = 0; |
| + |
| + // Block if IsExitConditionSatisfied() is currently false until TimedOut() |
| + // becomes true. Checkers should call CheckExitCondition upon changes, which |
| + // can cause Wait() to immediately return true if IsExitConditionSatisfied(), |
| + // and continue to block if not. Returns true if and only if timeout occurs. |
|
maxbogue
2016/09/30 19:03:53
This is wrong now: "Returns true if and only if ti
skym
2016/09/30 19:06:52
Done.
|
| + virtual bool Wait(); |
| + |
| // Returns true if the blocking wait was exited because of a timeout. |
| bool TimedOut() const; |
| - virtual bool IsExitConditionSatisfied() = 0; |
| - |
| protected: |
| virtual ~StatusChangeChecker(); |