chromium/ui/events/test/scoped_event_test_tick_clock.h

// Copyright 2018 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef UI_EVENTS_TEST_SCOPED_EVENT_TEST_TICK_CLOCK_H_
#define UI_EVENTS_TEST_SCOPED_EVENT_TEST_TICK_CLOCK_H_

#include "base/test/simple_test_tick_clock.h"
#include "base/time/time.h"
#include "ui/events/base_event_utils.h"

namespace ui {
namespace test {

// Helper class to mock ui events tick clock. On construction it registers a
// simple test tick clock for ui events. On destruction, it clears the test
// clock.
//
// Example:
//   TEST_F(SomeFixture, MyTest) {
//        ScopedEventTestTickClock clock;
//        clock.SetNowSeconds(1200);
//   }
class ScopedEventTestTickClock {};

}  // namespace test
}  // namespace ui

#endif  // UI_EVENTS_TEST_SCOPED_EVENT_TEST_TICK_CLOCK_H_