1 // Copyright 2018 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 #ifndef TOOLS_GN_TEST_WITH_SCHEDULER_H_ 6 #define TOOLS_GN_TEST_WITH_SCHEDULER_H_ 7 8 #include "base/macros.h" 9 #include "gn/scheduler.h" 10 #include "util/msg_loop.h" 11 #include "util/test/test.h" 12 13 class TestWithScheduler : public testing::Test { 14 protected: 15 TestWithScheduler(); 16 ~TestWithScheduler() override; 17 scheduler()18 Scheduler& scheduler() { return scheduler_; } 19 20 private: 21 MsgLoop run_loop_; 22 Scheduler scheduler_; 23 24 DISALLOW_COPY_AND_ASSIGN(TestWithScheduler); 25 }; 26 27 #endif // TOOLS_GN_TEST_WITH_SCHEDULER_H_ 28