#include "components/subresource_filter/content/browser/subresource_filter_test_harness.h"
#include <memory>
#include <utility>
#include "base/feature_list.h"
#include "base/run_loop.h"
#include "base/task/single_thread_task_runner.h"
#include "components/content_settings/browser/page_specific_content_settings.h"
#include "components/infobars/content/content_infobar_manager.h"
#include "components/infobars/core/confirm_infobar_delegate.h"
#include "components/infobars/core/infobar.h"
#include "components/safe_browsing/core/browser/db/v4_protocol_manager_util.h"
#include "components/subresource_filter/content/browser/content_subresource_filter_throttle_manager.h"
#include "components/subresource_filter/content/browser/content_subresource_filter_web_contents_helper.h"
#include "components/subresource_filter/content/browser/safe_browsing_ruleset_publisher.h"
#include "components/subresource_filter/content/browser/subresource_filter_content_settings_manager.h"
#include "components/subresource_filter/content/browser/subresource_filter_observer_test_utils.h"
#include "components/subresource_filter/content/browser/subresource_filter_profile_context.h"
#include "components/subresource_filter/content/browser/test_ruleset_publisher.h"
#include "components/subresource_filter/content/shared/browser/ruleset_service.h"
#include "components/subresource_filter/core/common/activation_decision.h"
#include "components/subresource_filter/core/common/activation_list.h"
#include "components/subresource_filter/core/common/constants.h"
#include "components/subresource_filter/core/common/test_ruleset_creator.h"
#include "components/subresource_filter/core/common/test_ruleset_utils.h"
#include "components/subresource_filter/core/mojom/subresource_filter.mojom.h"
#include "components/user_prefs/user_prefs.h"
#include "content/public/browser/browser_context.h"
#include "content/public/browser/browser_thread.h"
#include "content/public/browser/navigation_handle.h"
#include "content/public/browser/navigation_throttle.h"
#include "content/public/test/navigation_simulator.h"
#include "content/public/test/test_renderer_host.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "url/gurl.h"
namespace subresource_filter {
constexpr char const SubresourceFilterTestHarness::kDefaultAllowedSuffix[];
constexpr char const SubresourceFilterTestHarness::kDefaultDisallowedSuffix[];
constexpr char const SubresourceFilterTestHarness::kDefaultDisallowedUrl[];
SubresourceFilterTestHarness::SubresourceFilterTestHarness() = default;
SubresourceFilterTestHarness::~SubresourceFilterTestHarness() = default;
void SubresourceFilterTestHarness::SetUp() { … }
void SubresourceFilterTestHarness::TearDown() { … }
void SubresourceFilterTestHarness::DidStartNavigation(
content::NavigationHandle* navigation_handle) { … }
content::RenderFrameHost*
SubresourceFilterTestHarness::SimulateNavigateAndCommit(
const GURL& url,
content::RenderFrameHost* rfh) { … }
content::RenderFrameHost*
SubresourceFilterTestHarness::CreateAndNavigateDisallowedSubframe(
content::RenderFrameHost* parent) { … }
void SubresourceFilterTestHarness::ConfigureAsSubresourceFilterOnlyURL(
const GURL& url) { … }
void SubresourceFilterTestHarness::RemoveURLFromBlocklist(const GURL& url) { … }
SubresourceFilterContentSettingsManager*
SubresourceFilterTestHarness::GetSettingsManager() { … }
void SubresourceFilterTestHarness::SetIsAdFrame(
content::RenderFrameHost* render_frame_host,
bool is_ad_frame) { … }
}