Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(44)

Side by Side Diff: Source/web/tests/sim/SimNetwork.h

Issue 1313013005: Add a test that we resume commits after inserting the body. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: dcheng@ review Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/web/tests/sim/SimLayerTreeView.cpp ('k') | Source/web/tests/sim/SimNetwork.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef SimNetwork_h
6 #define SimNetwork_h
7
8 #include "public/platform/WebURLLoaderTestDelegate.h"
9 #include "wtf/HashMap.h"
10 #include "wtf/text/StringHash.h"
11 #include "wtf/text/WTFString.h"
12
13 namespace blink {
14
15 class SimRequest;
16 class WebURLLoader;
17 class WebURLLoaderClient;
18 class WebURLResponse;
19
20 class SimNetwork final : public WebURLLoaderTestDelegate {
21 public:
22 SimNetwork();
23 ~SimNetwork();
24
25 private:
26 friend class SimRequest;
27
28 static SimNetwork& current();
29
30 void servePendingRequests();
31 void addRequest(SimRequest&);
32 void removeRequest(SimRequest&);
33
34 // WebURLLoaderTestDelegate
35 void didReceiveResponse(WebURLLoaderClient*, WebURLLoader*, const WebURLResp onse&) override;
36 void didReceiveData(WebURLLoaderClient*, WebURLLoader*, const char* data, in t dataLength, int encodedDataLength) override;
37 void didFail(WebURLLoaderClient*, WebURLLoader*, const WebURLError&) overrid e;
38 void didFinishLoading(WebURLLoaderClient*, WebURLLoader*, double finishTime, int64_t totalEncodedDataLength) override;
39
40 SimRequest* m_currentRequest;
41 HashMap<String, SimRequest*> m_requests;
42 };
43
44 } // namespace blink
45
46 #endif
OLDNEW
« no previous file with comments | « Source/web/tests/sim/SimLayerTreeView.cpp ('k') | Source/web/tests/sim/SimNetwork.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698