Skip to content

Commit c9eb35e

Browse files
committed
fix unit test
Signed-off-by: Salvetti, Francesco <[email protected]>
1 parent 292ff53 commit c9eb35e

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/test_loops.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ def test_while_loop_cond_subgraphs(self):
308308
def func(x):
309309
x_dim = tf.shape(x)[0]
310310
r = tf.cast(tf.zeros(1), x.dtype)
311-
for i in range(tf.constant(10)):
311+
for i in tf.range(10):
312312
if i == x_dim:
313313
break
314314
r += x[i]
@@ -319,4 +319,4 @@ def func(x):
319319
self.run_test_case(func, feed_dict, input_names_with_port, output_names_with_port)
320320

321321
if __name__ == '__main__':
322-
unittest_main()
322+
unittest_main()

0 commit comments

Comments
 (0)