21 #ifndef NET_INSTAWEB_REWRITER_PUBLIC_CUSTOM_REWRITE_TEST_BASE_H_
22 #define NET_INSTAWEB_REWRITER_PUBLIC_CUSTOM_REWRITE_TEST_BASE_H_
31 namespace net_instaweb {
33 template<
class OptionsClass>
45 return new OptionsClass(thread_system());
53 virtual ~CustomRewriteTestBase() {
54 OptionsClass::Terminate();
61 OptionsClass* NewOptions() {
62 return new OptionsClass(factory()->thread_system());
71 static std::pair<TestRewriteDriverFactory*, TestRewriteDriverFactory*>
73 OptionsClass::Initialize();
76 new CustomTestRewriteDriverFactory(mock_fetcher),
77 new CustomTestRewriteDriverFactory(mock_fetcher));
Definition: test_rewrite_driver_factory.h:67
static const ProcessContext & process_context()
void InitializeDefaultOptions()
Definition: rewrite_test_base.h:90
Definition: custom_rewrite_test_base.h:36
virtual OptionsClass * NewRewriteOptions()
Note that this disables ajax rewriting by default.
Definition: custom_rewrite_test_base.h:44
virtual TestRewriteDriverFactory * MakeTestFactory()
Definition: custom_rewrite_test_base.h:57
RewriteOptions * options_
owned by rewrite_driver_.
Definition: rewrite_test_base.h:845
Definition: mock_url_fetcher.h:41
MockUrlFetcher mock_url_fetcher_
Definition: rewrite_test_base.h:822
OptionsClass * options()
Non-virtual override of options method defined in RewriteTestBase.
Definition: custom_rewrite_test_base.h:66
Definition: custom_rewrite_test_base.h:34