diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2017-04-11 08:52:06 -0800 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2017-04-11 10:05:47 -0700 |
commit | 5c8acccfc9e90d694a8394f5522097bfe87379b2 (patch) | |
tree | 14a599c7ca3e73bcb09cd565a07da1aa87ef20d5 /tensorflow/compiler/xla/status_macros_test.cc | |
parent | 315443bbb01719a9e417826c4a077c47056bc071 (diff) |
Using GMock matchers in XLA tests.
Change: 152823724
Diffstat (limited to 'tensorflow/compiler/xla/status_macros_test.cc')
-rw-r--r-- | tensorflow/compiler/xla/status_macros_test.cc | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/tensorflow/compiler/xla/status_macros_test.cc b/tensorflow/compiler/xla/status_macros_test.cc index 4e7b9161db..5563159776 100644 --- a/tensorflow/compiler/xla/status_macros_test.cc +++ b/tensorflow/compiler/xla/status_macros_test.cc @@ -16,9 +16,9 @@ limitations under the License. #include "tensorflow/compiler/xla/status_macros.h" #include "tensorflow/compiler/xla/statusor.h" +#include "tensorflow/compiler/xla/test.h" #include "tensorflow/compiler/xla/test_helpers.h" #include "tensorflow/core/lib/core/errors.h" -#include "tensorflow/core/platform/test.h" namespace xla { @@ -40,15 +40,15 @@ Status RetCheckSuccess() { TEST(StatusMacros, RetCheckFailing) { Status status = RetCheckFail(); EXPECT_EQ(status.code(), tensorflow::error::INTERNAL); - EXPECT_MATCH(status.error_message(), - xla::testing::ContainsRegex("RET_CHECK failure.*2 > 3")); + EXPECT_THAT(status.error_message(), + ::testing::ContainsRegex("RET_CHECK failure.*2 > 3")); } TEST(StatusMacros, RetCheckFailingWithExtraMessage) { Status status = RetCheckFailWithExtraMessage(); EXPECT_EQ(status.code(), tensorflow::error::INTERNAL); - EXPECT_MATCH(status.error_message(), - xla::testing::ContainsRegex("RET_CHECK.*2 > 3 extra message")); + EXPECT_THAT(status.error_message(), + ::testing::ContainsRegex("RET_CHECK.*2 > 3 extra message")); } TEST(StatusMacros, RetCheckSucceeding) { |