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

Side by Side Diff: mojo/common/test/test_utils.h

Issue 253413004: Enable mojo js tests which depend on mojom.js files in gen/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 8 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 | « mojo/bindings/js/run_js_tests.cc ('k') | mojo/common/test/test_utils_posix.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MOJO_COMMON_TEST_TEST_UTILS_H_ 5 #ifndef MOJO_COMMON_TEST_TEST_UTILS_H_
6 #define MOJO_COMMON_TEST_TEST_UTILS_H_ 6 #define MOJO_COMMON_TEST_TEST_UTILS_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <string>
11
12 #include "base/files/file_path.h"
13
10 namespace mojo { 14 namespace mojo {
11 15
12 namespace embedder { 16 namespace embedder {
13 struct PlatformHandle; 17 struct PlatformHandle;
14 } 18 }
15 19
16 namespace test { 20 namespace test {
17 21
18 // On success, |bytes_written| is updated to the number of bytes written; 22 // On success, |bytes_written| is updated to the number of bytes written;
19 // otherwise it is untouched. 23 // otherwise it is untouched.
(...skipping 11 matching lines...) Expand all
31 35
32 // If the read is done successfully or would block, the function returns true 36 // If the read is done successfully or would block, the function returns true
33 // and updates |bytes_read| to the number of bytes read (0 if the read would 37 // and updates |bytes_read| to the number of bytes read (0 if the read would
34 // block); otherwise it returns false and leaves |bytes_read| untouched. 38 // block); otherwise it returns false and leaves |bytes_read| untouched.
35 // |handle| must already be in non-blocking mode. 39 // |handle| must already be in non-blocking mode.
36 bool NonBlockingRead(const embedder::PlatformHandle& handle, 40 bool NonBlockingRead(const embedder::PlatformHandle& handle,
37 void* buffer, 41 void* buffer,
38 size_t buffer_size, 42 size_t buffer_size,
39 size_t* bytes_read); 43 size_t* bytes_read);
40 44
45 // Returns the path to the mojom js bindings file.
46 base::FilePath GetFilePathForJSResource(const std::string& path);
47
41 } // namespace test 48 } // namespace test
42 } // namespace mojo 49 } // namespace mojo
43 50
44 #endif // MOJO_COMMON_TEST_TEST_UTILS_H_ 51 #endif // MOJO_COMMON_TEST_TEST_UTILS_H_
OLDNEW
« no previous file with comments | « mojo/bindings/js/run_js_tests.cc ('k') | mojo/common/test/test_utils_posix.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698