#include "base/task/thread_pool/sequence.h"
#include <optional>
#include <utility>
#include "base/functional/bind.h"
#include "base/functional/callback_helpers.h"
#include "base/memory/ptr_util.h"
#include "base/test/gtest_util.h"
#include "base/time/time.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
namespace base {
namespace internal {
namespace {
class MockTask { … };
Task CreateTask(MockTask* mock_task, TimeTicks now = TimeTicks::Now()) { … }
Task CreateDelayedTask(MockTask* mock_task,
TimeDelta delay,
TimeTicks now = TimeTicks::Now()) { … }
void ExpectMockTask(MockTask* mock_task, Task* task) { … }
}
TEST(ThreadPoolSequenceTest, PushTakeRemove) { … }
TEST(ThreadPoolSequenceTest, GetSortKeyBestEffort) { … }
TEST(ThreadPoolSequenceTest, GetSortKeyForeground) { … }
TEST(ThreadPoolSequenceTest, DidProcessTaskWithoutWillRunTask) { … }
TEST(ThreadPoolSequenceTest, TakeEmptyFrontSlot) { … }
TEST(ThreadPoolSequenceTest, TakeEmptySequence) { … }
TEST(ThreadPoolSequenceTest, SequenceHasWorker) { … }
TEST(ThreadPoolSequenceTest, PushTakeRemoveDelayedTasks) { … }
TEST(ThreadPoolSequenceTest, PushTakeRemoveMixedTasks) { … }
TEST(ThreadPoolSequenceTest, TestPushDelayedTaskMethodUsage) { … }
TEST(ThreadPoolSequenceTest, GetDelayedSortKeyMixedtasks) { … }
TEST(ThreadPoolSequenceTest, GetDelayedSortKeyDelayedtasks) { … }
}
}