#include "extensions/browser/api/offscreen/audio_lifetime_enforcer.h"
#include <optional>
#include "base/run_loop.h"
#include "base/test/bind.h"
#include "chrome/browser/extensions/extension_apitest.h"
#include "chrome/browser/extensions/extension_util.h"
#include "chrome/browser/profiles/profile.h"
#include "components/version_info/channel.h"
#include "content/public/test/browser_test.h"
#include "content/public/test/browser_test_utils.h"
#include "content/public/test/test_navigation_observer.h"
#include "extensions/browser/extension_util.h"
#include "extensions/browser/offscreen_document_host.h"
#include "extensions/browser/process_manager.h"
#include "extensions/common/extension.h"
#include "extensions/test/test_extension_dir.h"
namespace extensions {
namespace {
class AudioWaiter : public content::WebContentsObserver { … };
}
class AudioLifetimeEnforcerBrowserTest : public ExtensionApiTest { … };
IN_PROC_BROWSER_TEST_F(AudioLifetimeEnforcerBrowserTest,
DocumentActiveWhilePlayingAudio) { … }
IN_PROC_BROWSER_TEST_F(AudioLifetimeEnforcerBrowserTest,
DocumentInactiveIfNeverPlayedAudio) { … }
}