forked from chromium/chromium
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathchrome_mock_render_thread.h
34 lines (24 loc) · 1.1 KB
/
chrome_mock_render_thread.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef CHROME_RENDERER_CHROME_MOCK_RENDER_THREAD_H_
#define CHROME_RENDERER_CHROME_MOCK_RENDER_THREAD_H_
#include <string>
#include "base/macros.h"
#include "content/public/test/mock_render_thread.h"
// Extends content::MockRenderThread to know about extension messages.
class ChromeMockRenderThread : public content::MockRenderThread {
public:
ChromeMockRenderThread();
~ChromeMockRenderThread() override;
// content::RenderThread overrides.
scoped_refptr<base::SingleThreadTaskRunner> GetIOTaskRunner() override;
//////////////////////////////////////////////////////////////////////////
// The following functions are called by the test itself.
void set_io_task_runner(
const scoped_refptr<base::SingleThreadTaskRunner>& task_runner);
protected:
scoped_refptr<base::SingleThreadTaskRunner> io_task_runner_;
DISALLOW_COPY_AND_ASSIGN(ChromeMockRenderThread);
};
#endif // CHROME_RENDERER_CHROME_MOCK_RENDER_THREAD_H_