From 374d186a2976c8ec5b1e0e7cb16880983255ad09 Mon Sep 17 00:00:00 2001 From: Yu Xiao Date: Wed, 13 Sep 2023 14:56:58 -0700 Subject: [PATCH] Remove the copybara replacement of the error message. PiperOrigin-RevId: 565170171 --- .../python/tensorflow_libs/variable_utils_test.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tensorflow_federated/python/tensorflow_libs/variable_utils_test.py b/tensorflow_federated/python/tensorflow_libs/variable_utils_test.py index 2eb5354440..cc286e8e37 100644 --- a/tensorflow_federated/python/tensorflow_libs/variable_utils_test.py +++ b/tensorflow_federated/python/tensorflow_libs/variable_utils_test.py @@ -226,7 +226,8 @@ def test_scalar_getitem_fails(self, value): value = tf.convert_to_tensor(value) tensor_variable = variable_utils.TensorVariable(value) with self.assertRaisesRegex( - tf.errors.InvalidArgumentError, 'Index out of range' + tf.errors.InvalidArgumentError, + 'Attempting to slice scalar input', ): _ = tensor_variable[0]