aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/python/eager/ops_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'tensorflow/python/eager/ops_test.py')
-rw-r--r--tensorflow/python/eager/ops_test.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/tensorflow/python/eager/ops_test.py b/tensorflow/python/eager/ops_test.py
index fc76ede4c5..17a090d526 100644
--- a/tensorflow/python/eager/ops_test.py
+++ b/tensorflow/python/eager/ops_test.py
@@ -370,6 +370,10 @@ class OpsTest(test_util.TensorFlowTestCase):
with self.assertRaises(TypeError):
float(x)
+ def testRange(self):
+ x = constant_op.constant(2)
+ self.assertEqual([0, 1], list(range(x)))
+
def testFormatString(self):
x = constant_op.constant(3.1415)
self.assertEqual('3.14', '{:.2f}'.format(x))