Test case 1: one input for the map function with no captured inputs.
| 78 | |
| 79 | // Test case 1: one input for the map function with no captured inputs. |
| 80 | TestCase TestCase1() { |
| 81 | return { |
| 82 | /*arguments*/ { |
| 83 | CreateTensor<int64>(TensorShape({3, 2}), {0, 1, 2, 3, 4, 5})}, |
| 84 | /*captured_inputs*/ {}, |
| 85 | /*t_arguments*/ {DT_INT64}, |
| 86 | /*t_captured*/ {}, |
| 87 | /*func*/ {FunctionDefHelper::FunctionRef("XTimesTwo", {{"T", DT_INT64}})}, |
| 88 | /*func_lib*/ {test::function::XTimesTwo()}, |
| 89 | /*max_intra_op_parallelism*/ 2, |
| 90 | /*output_dtypes*/ {DT_INT64}, |
| 91 | /*output_shapes*/ {PartialTensorShape({2})}, |
| 92 | /*expected_outputs*/ |
| 93 | {CreateTensor<int64>(TensorShape({3, 2}), {0, 2, 4, 6, 8, 10})}}; |
| 94 | } |
| 95 | |
| 96 | // Test case 2: two inputs for the map function with no captured inputs. |
| 97 | TestCase TestCase2() { |
no test coverage detected