tests/spec/unit/output/output_sections_6.mzn
raw| 1 | /*** |
| 2 | !Test |
| 3 | solvers: [gecode] |
| 4 | expected: !Result |
| 5 | solution: !Solution |
| 6 | _output_item: "output_to_section: 10\noutput_item: 10\n" |
| 7 | ***/ |
| 8 | |
| 9 | var 1..10: x :: foo; |
| 10 | |
| 11 | annotation foo(var int: x :: annotated_expression) = let { |
| 12 | constraint output_to_section("default", "output_to_section: \(x)\n"); |
| 13 | } in empty_annotation; |
| 14 | |
| 15 | solve maximize x; |
| 16 | |
| 17 | output ["output_item: \(x)\n"]; |