Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 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 | import("../../mojo_edk.gni") |
| 6 | |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 7 | # Utilties for use by EDK internal (unit and perf) tests. |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 8 | mojo_edk_source_set("test") { |
| 9 | testonly = true |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 10 | mojo_edk_visibility = [ "mojo/edk/*" ] |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 11 | |
| 12 | sources = [ |
| 13 | "random.cc", |
| 14 | "random.h", |
Viet-Trung Luu | d892e47 | 2015-10-29 09:16:40 -0700 | [diff] [blame] | 15 | "scoped_test_dir.cc", |
| 16 | "scoped_test_dir.h", |
Viet-Trung Luu | 7b392e0 | 2015-10-28 16:52:55 -0700 | [diff] [blame] | 17 | "simple_test_thread.cc", |
| 18 | "simple_test_thread.h", |
Viet-Trung Luu | d91741a | 2015-11-05 14:36:01 -0800 | [diff] [blame] | 19 | "test_command_line.cc", |
| 20 | "test_command_line.h", |
Viet-Trung Luu | d892e47 | 2015-10-29 09:16:40 -0700 | [diff] [blame] | 21 | "test_io_thread.cc", |
| 22 | "test_io_thread.h", |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 23 | "timeouts.cc", |
| 24 | "timeouts.h", |
| 25 | ] |
| 26 | |
| 27 | mojo_sdk_public_deps = [ |
| 28 | "mojo/public/c/system", |
| 29 | "mojo/public/cpp/system", |
| 30 | ] |
| 31 | |
| 32 | deps = [ |
| 33 | "//base", |
| 34 | "//base/test:test_support", |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 35 | "//testing/gtest", |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 36 | ] |
| 37 | |
Viet-Trung Luu | d892e47 | 2015-10-29 09:16:40 -0700 | [diff] [blame] | 38 | mojo_edk_deps = [ |
Viet-Trung Luu | 1da183c | 2015-11-18 15:41:35 -0800 | [diff] [blame] | 39 | "mojo/edk/base_edk", |
Viet-Trung Luu | d892e47 | 2015-10-29 09:16:40 -0700 | [diff] [blame] | 40 | "mojo/edk/util", |
| 41 | ] |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 42 | } |
| 43 | |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 44 | # Utilities for use by EDK internal perf tests (for use with |
| 45 | # :run_all_perftests). |
| 46 | mojo_edk_source_set("perf") { |
| 47 | testonly = true |
| 48 | mojo_edk_visibility = [ "mojo/edk/*" ] |
| 49 | |
| 50 | sources = [ |
| 51 | "perf_log.cc", |
| 52 | "perf_log.h", |
| 53 | ] |
| 54 | |
| 55 | deps = [ |
| 56 | "//base/test:test_support", |
| 57 | ] |
| 58 | } |
| 59 | |
| 60 | mojo_edk_source_set("run_all_unittests") { |
| 61 | testonly = true |
| 62 | mojo_edk_visibility = [ "mojo/edk/*" ] |
| 63 | |
| 64 | sources = [ |
| 65 | "run_all_unittests.cc", |
| 66 | ] |
| 67 | |
| 68 | deps = [ |
Viet-Trung Luu | d91741a | 2015-11-05 14:36:01 -0800 | [diff] [blame] | 69 | ":test", |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 70 | "//base", |
| 71 | "//base/test:test_support", |
| 72 | "//testing/gtest", |
| 73 | ] |
| 74 | } |
| 75 | |
| 76 | mojo_edk_source_set("run_all_perftests") { |
| 77 | testonly = true |
| 78 | mojo_edk_visibility = [ "mojo/edk/*" ] |
| 79 | |
| 80 | sources = [ |
| 81 | "run_all_perftests.cc", |
| 82 | ] |
| 83 | |
| 84 | deps = [ |
Viet-Trung Luu | d91741a | 2015-11-05 14:36:01 -0800 | [diff] [blame] | 85 | ":test", |
Viet-Trung Luu | b7cd10b | 2015-10-30 09:47:47 -0700 | [diff] [blame] | 86 | "//base/test:test_support", |
| 87 | ] |
| 88 | } |
| 89 | |
Viet-Trung Luu | c2ad309 | 2015-11-09 13:43:00 -0800 | [diff] [blame] | 90 | mojo_edk_unittests("mojo_edk_system_test_unittests") { |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 91 | sources = [ |
| 92 | "random_unittest.cc", |
Viet-Trung Luu | cb67849 | 2015-10-28 12:46:54 -0700 | [diff] [blame] | 93 | ] |
| 94 | |
| 95 | deps = [ |
| 96 | ":test", |
| 97 | "//testing/gtest", |
| 98 | ] |
| 99 | } |