(self)
| 138 | |
| 139 | @test_util.run_deprecated_v1 |
| 140 | def testBasic2(self): |
| 141 | x = constant_op.constant(1.0, name="x") |
| 142 | y = constant_op.constant(2.0, name="y") |
| 143 | |
| 144 | def true_fn(): |
| 145 | return x * y * 2.0 |
| 146 | |
| 147 | def false_fn(): |
| 148 | return 2.0 |
| 149 | |
| 150 | self._testCond(true_fn, false_fn, [x]) |
| 151 | self._testCond(true_fn, false_fn, [x, y]) |
| 152 | self._testCond(true_fn, false_fn, [y]) |
| 153 | |
| 154 | @test_util.run_deprecated_v1 |
| 155 | def testNoInputs(self): |