OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 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 CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_TEST_COMMON_H_ | |
6 #define CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_TEST_COMMON_H_ | |
7 | |
8 #include "net/test/embedded_test_server/http_request.h" | |
9 #include "net/test/embedded_test_server/http_response.h" | |
10 #include "url/gurl.h" | |
11 | |
12 using net::test_server::HttpRequest; | |
13 using net::test_server::HttpResponse; | |
14 | |
15 namespace chromeos { | |
16 | |
17 class KioskTestCommon { | |
xiyuan
2014/05/09 20:49:15
Let's move more stuff into this class and make a F
jennyz
2014/05/13 00:31:21
Done.
| |
18 public: | |
19 KioskTestCommon() {} | |
20 virtual ~KioskTestCommon() {} | |
21 | |
22 protected: | |
23 // Sets up |update_check_content_| used in update request response later by | |
24 // kiosk app update server requeset handler |HandleRequest|. | |
25 void SetUpdateCheckContent(const std::string& update_check_file, | |
26 const GURL& crx_download_url, | |
27 const std::string& app_id, | |
28 const std::string& crx_fp, | |
29 const std::string& crx_size, | |
30 const std::string& version, | |
31 std::string* update_check_content); | |
32 | |
33 // Request handler for kiosk app update server. | |
34 scoped_ptr<HttpResponse> HandleRequest(const HttpRequest& request); | |
35 | |
36 // Sets up the kiosk app update response. | |
37 void SetUpdateCrx(const GURL& webstore_url, | |
38 const std::string& crx_donwload_path, | |
39 const std::string& app_id, | |
40 const std::string& crx_file, | |
41 const std::string& version); | |
42 | |
43 std::string update_check_content_; | |
44 | |
45 private: | |
46 DISALLOW_COPY_AND_ASSIGN(KioskTestCommon); | |
47 }; | |
48 | |
49 } // namespace chromeos | |
50 | |
51 #endif // CHROME_BROWSER_CHROMEOS_APP_MODE_KIOSK_TEST_COMMON_H_ | |
OLD | NEW |