#include "third_party/blink/renderer/platform/scheduler/common/scheduler_helper.h"
#include "base/functional/bind.h"
#include "base/functional/callback.h"
#include "base/task/common/lazy_now.h"
#include "base/task/sequence_manager/task_queue.h"
#include "base/task/sequence_manager/test/sequence_manager_for_test.h"
#include "base/task/single_thread_task_runner.h"
#include "base/task/task_observer.h"
#include "base/test/task_environment.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/platform/scheduler/common/task_priority.h"
#include "third_party/blink/renderer/platform/scheduler/worker/non_main_thread_scheduler_helper.h"
#include "third_party/blink/renderer/platform/wtf/text/wtf_string.h"
#include "third_party/blink/renderer/platform/wtf/vector.h"
_;
AnyNumber;
Invoke;
Return;
namespace blink {
namespace scheduler {
namespace scheduler_helper_unittest {
namespace {
void AppendToVectorTestTask(Vector<String>* vector, String value) { … }
void AppendToVectorReentrantTask(base::SingleThreadTaskRunner* task_runner,
Vector<int>* vector,
int* reentrant_count,
int max_reentrant_count) { … }
}
class SchedulerHelperTest : public testing::Test { … };
TEST_F(SchedulerHelperTest, TestPostDefaultTask) { … }
TEST_F(SchedulerHelperTest, TestRentrantTask) { … }
TEST_F(SchedulerHelperTest, IsShutdown) { … }
TEST_F(SchedulerHelperTest, GetNumberOfPendingTasks) { … }
namespace {
class MockTaskObserver : public base::TaskObserver { … };
void NopTask() { … }
}
TEST_F(SchedulerHelperTest, ObserversNotifiedFor_DefaultTaskRunner) { … }
TEST_F(SchedulerHelperTest, ObserversNotNotifiedFor_ControlTaskQueue) { … }
}
}
}