#include "extensions/browser/api/idle/idle_api.h"
#include <limits.h>
#include <memory>
#include <string>
#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/strings/string_number_conversions.h"
#include "extensions/browser/api/idle/idle_api_constants.h"
#include "extensions/browser/api/idle/idle_manager.h"
#include "extensions/browser/api/idle/idle_manager_factory.h"
#include "extensions/browser/api/idle/test_idle_provider.h"
#include "extensions/browser/api_unittest.h"
#include "extensions/browser/event_router.h"
#include "extensions/browser/extension_registry.h"
#include "extensions/browser/unloaded_extension_reason.h"
#include "extensions/common/api/idle.h"
#include "extensions/common/extension.h"
#include "extensions/common/extension_id.h"
#include "testing/gmock/include/gmock/gmock.h"
#include "testing/gtest/include/gtest/gtest.h"
_;
idle;
namespace extensions {
namespace {
class MockEventDelegate : public IdleManager::EventDelegate { … };
class ScopedListen { … };
ScopedListen::ScopedListen(IdleManager* idle_manager,
const ExtensionId& extension_id)
: … { … }
ScopedListen::~ScopedListen() { … }
std::unique_ptr<KeyedService> IdleManagerTestFactory(
content::BrowserContext* context) { … }
}
class IdleTest : public ApiUnitTest { … };
void IdleTest::SetUp() { … }
TEST_F(IdleTest, QueryLockedActive) { … }
TEST_F(IdleTest, QueryLockedIdle) { … }
TEST_F(IdleTest, QueryActive) { … }
TEST_F(IdleTest, QueryIdle) { … }
TEST_F(IdleTest, QueryMinThreshold) { … }
TEST_F(IdleTest, QueryMaxThreshold) { … }
TEST_F(IdleTest, ActiveToIdle) { … }
TEST_F(IdleTest, ActiveToLocked) { … }
TEST_F(IdleTest, IdleToActive) { … }
TEST_F(IdleTest, IdleToLocked) { … }
TEST_F(IdleTest, LockedToActive) { … }
TEST_F(IdleTest, LockedToIdle) { … }
TEST_F(IdleTest, MultipleExtensions) { … }
TEST_F(IdleTest, SetDetectionInterval) { … }
TEST_F(IdleTest, SetDetectionIntervalBeforeListener) { … }
TEST_F(IdleTest, SetDetectionIntervalMaximum) { … }
TEST_F(IdleTest, SetDetectionIntervalMinimum) { … }
TEST_F(IdleTest, UnloadCleanup) { … }
TEST_F(IdleTest, UnloadOnly) { … }
TEST_F(IdleTest, UnloadWhileListening) { … }
TEST_F(IdleTest, ReAddListener) { … }
}