chromium/extensions/browser/api/power/power_api_unittest.cc

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

#include "extensions/browser/api/power/power_api.h"

#include <memory>
#include <string>

#include "base/containers/circular_deque.h"
#include "base/functional/bind.h"
#include "base/memory/raw_ptr.h"
#include "base/memory/scoped_refptr.h"
#include "extensions/browser/api_test_utils.h"
#include "extensions/browser/api_unittest.h"
#include "extensions/browser/unloaded_extension_reason.h"
#include "extensions/common/extension.h"
#include "extensions/common/extension_builder.h"
#include "services/device/public/mojom/wake_lock.mojom-shared.h"

namespace extensions {

namespace {

// Args commonly passed to FakeWakeLockManager::CallFunction().
const char kDisplayArgs[] =;
const char kSystemArgs[] =;
const char kEmptyArgs[] =;

// Different actions that can be performed as a result of a
// wake lock being activated or cancelled.
enum Request {};

// Tests instantiate this class to make PowerAPI's calls to simulate activate
// and cancel the wake locks and record the actions that would've been performed
// instead of actually blocking and unblocking power management.
class FakeWakeLockManager {};

}  // namespace

class PowerAPITest : public ApiUnitTest {};

TEST_F(PowerAPITest, RequestAndRelease) {}

TEST_F(PowerAPITest, RequestWithoutRelease) {}

TEST_F(PowerAPITest, ReleaseWithoutRequest) {}

TEST_F(PowerAPITest, UpgradeRequest) {}

TEST_F(PowerAPITest, DowngradeRequest) {}

TEST_F(PowerAPITest, MultipleExtensions) {}

}  // namespace extensions