Tom Finegan | e9d70c9 | 2017-05-10 11:31:05 -0700 | [diff] [blame] | 1 | ## |
| 2 | ## Copyright (c) 2017, Alliance for Open Media. All rights reserved |
| 3 | ## |
| 4 | ## This source code is subject to the terms of the BSD 2 Clause License and |
| 5 | ## the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License |
| 6 | ## was not distributed with this source code in the LICENSE file, you can |
| 7 | ## obtain it at www.aomedia.org/license/software. If the Alliance for Open |
| 8 | ## Media Patent License 1.0 was not distributed with this source code in the |
| 9 | ## PATENTS file, you can obtain it at www.aomedia.org/license/patent. |
| 10 | ## |
Tom Finegan | d1cbd8c | 2017-05-18 14:14:56 -0700 | [diff] [blame] | 11 | if (NOT GTEST_TOTAL_SHARDS OR "${GTEST_SHARD_INDEX}" STREQUAL "" |
| 12 | OR NOT TEST_LIBAOM) |
Tom Finegan | e9d70c9 | 2017-05-10 11:31:05 -0700 | [diff] [blame] | 13 | message(FATAL_ERROR |
Tom Finegan | d1cbd8c | 2017-05-18 14:14:56 -0700 | [diff] [blame] | 14 | "The variables GTEST_SHARD_INDEX, GTEST_TOTAL_SHARDS and TEST_LIBAOM |
| 15 | must be defined.") |
Tom Finegan | e9d70c9 | 2017-05-10 11:31:05 -0700 | [diff] [blame] | 16 | endif () |
| 17 | |
| 18 | set($ENV{GTEST_SHARD_INDEX} ${GTEST_SHARD_INDEX}) |
| 19 | set($ENV{GTEST_TOTAL_SHARDS} ${GTEST_TOTAL_SHARDS}) |
Tom Finegan | d5aff9d | 2017-07-13 13:02:38 -0700 | [diff] [blame] | 20 | execute_process(COMMAND ${TEST_LIBAOM} RESULT_VARIABLE test_result) |
| 21 | set(test_message "Test shard ${GTEST_SHARD_INDEX}/${GTEST_TOTAL_SHARDS} result") |
| 22 | message("${test_message}: ${test_result}") |