// Copyright 2018 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef COMPONENTS_SAFE_SEARCH_API_STUB_URL_CHECKER_H_ #define COMPONENTS_SAFE_SEARCH_API_STUB_URL_CHECKER_H_ #include <memory> #include <string> #include "base/memory/scoped_refptr.h" #include "net/base/net_errors.h" #include "services/network/test/test_url_loader_factory.h" namespace network { class SharedURLLoaderFactory; } // namespace network namespace safe_search_api { class URLChecker; // Helper class to stub out a URLLoaderFactory for use with URLChecker. This // lets tests control the response the URLChecker will receive from the Safe // Search API. Used to test both URLChecker itself and classes that use it. // This class builds a real URLChecker but maintains control over it to set up // fake responses. class StubURLChecker { … }; } // namespace safe_search_api #endif // COMPONENTS_SAFE_SEARCH_API_STUB_URL_CHECKER_H_