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

Side by Side Diff: net/test/url_request/ssl_certificate_error_job.h

Issue 1239543003: [Cronet] Surface SSL cert error through CronetURLRequestAdapter::OnSSLCertificateError (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address comments Created 5 years, 5 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
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 NET_TEST_URL_REQUEST_SSL_CERTIFICATE_ERROR_JOB_H_
6 #define NET_TEST_URL_REQUEST_SSL_CERTIFICATE_ERROR_JOB_H_
7
8 #include "base/macros.h"
9 #include "base/memory/weak_ptr.h"
10 #include "net/url_request/url_request_test_job.h"
11 #include "url/gurl.h"
12
13 namespace net {
14
15 // SSLCertificateErrorJob simulates a ERR_CERT_DATE_INVALID error.
16 class SSLCertificateErrorJob : public URLRequestTestJob {
mmenke 2015/07/17 21:09:18 Suggest using URLRequestJob instead. URLRequestTe
xunjieli 2015/07/20 14:56:20 Done.
17 public:
18 SSLCertificateErrorJob(URLRequest* request,
19 NetworkDelegate* network_delegate);
mmenke 2015/07/17 21:09:18 Nit: Should forward declare NetworkDelegate and U
xunjieli 2015/07/20 14:56:20 Done.
20
21 // URLRequestTestJob implementation:
22 void Start() override;
23
24 // Adds the testing URLs to the URLRequestFilter.
25 static void AddUrlHandler();
26
27 static GURL GetMockUrl();
28
29 private:
30 ~SSLCertificateErrorJob() override;
31 void NotifyError();
mmenke 2015/07/17 21:09:18 nit: Blank line after destructor declaration.
xunjieli 2015/07/20 14:56:20 Done.
32
33 base::WeakPtrFactory<SSLCertificateErrorJob> weak_factory_;
34
35 DISALLOW_COPY_AND_ASSIGN(SSLCertificateErrorJob);
36 };
37
38 } // namespace net
39
40 #endif // NET_TEST_URL_REQUEST_SSL_CERTIFICATE_ERROR_JOB_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698