diff options
author | Justin Lebar <jlebar@google.com> | 2017-03-14 08:23:40 -0800 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2017-03-14 09:43:41 -0700 |
commit | 1c1d6f54574c14ff47257f0e855fbd86e678c828 (patch) | |
tree | 7bc255f8df587233b13adb64e7e17248e6c0ec9f /tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc | |
parent | 40d8721dccfddb2fb144ebcc89f9fce26bc885f5 (diff) |
Use or explicitly ignore tensorflow::Status objects.
Change: 150075644
Diffstat (limited to 'tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc')
-rw-r--r-- | tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc b/tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc index 099e1d42aa..52afa5dde1 100644 --- a/tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc +++ b/tensorflow/core/kernels/remote_fused_graph_execute_utils_test.cc @@ -19,6 +19,7 @@ limitations under the License. #include "tensorflow/core/common_runtime/shape_refiner.h" #include "tensorflow/core/kernels/remote_fused_graph_execute_op_test_utils.h" #include "tensorflow/core/lib/core/status.h" +#include "tensorflow/core/lib/core/status_test_util.h" #include "tensorflow/core/platform/test.h" namespace tensorflow { @@ -188,34 +189,38 @@ TEST(RemoteFusedGraphExecuteUtils, PropagateAndBuildTensorShapeMap) { { NodeDef* node_def = GetNodeDef(NAME_B, &def); - RemoteFusedGraphExecuteUtils::AddOutputTensorShapeTypeByTensorShapeMap( - tensor_shape_map, node_def); + TF_ASSERT_OK( + RemoteFusedGraphExecuteUtils::AddOutputTensorShapeTypeByTensorShapeMap( + tensor_shape_map, node_def)); std::vector<DataType> data_types; - GetNodeAttr(*node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_DATA_TYPES, - &data_types); + TF_ASSERT_OK(GetNodeAttr( + *node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_DATA_TYPES, + &data_types)); ASSERT_EQ(1, data_types.size()); EXPECT_EQ(DT_FLOAT, data_types.at(0)); std::vector<TensorShape> shapes; - GetNodeAttr(*node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_SHAPES, - &shapes); + TF_ASSERT_OK(GetNodeAttr( + *node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_SHAPES, &shapes)); ASSERT_EQ(1, shapes.size()); EXPECT_EQ(0, shapes.at(0).dims()); } { NodeDef* node_def = GetNodeDef(NAME_A_PLUS_B, &def); - RemoteFusedGraphExecuteUtils::AddOutputTensorShapeTypeByTensorShapeMap( - tensor_shape_map, node_def); + TF_ASSERT_OK( + RemoteFusedGraphExecuteUtils::AddOutputTensorShapeTypeByTensorShapeMap( + tensor_shape_map, node_def)); std::vector<DataType> data_types; - GetNodeAttr(*node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_DATA_TYPES, - &data_types); + TF_ASSERT_OK(GetNodeAttr( + *node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_DATA_TYPES, + &data_types)); ASSERT_EQ(1, data_types.size()); EXPECT_EQ(DT_FLOAT, data_types.at(0)); std::vector<TensorShape> shapes; - GetNodeAttr(*node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_SHAPES, - &shapes); + TF_ASSERT_OK(GetNodeAttr( + *node_def, RemoteFusedGraphExecuteUtils::ATTR_OUTPUT_SHAPES, &shapes)); ASSERT_EQ(1, shapes.size()); EXPECT_EQ(0, shapes.at(0).dims()); } |