File tree Expand file tree Collapse file tree 1 file changed +22
-0
lines changed
exercises/practice/robot-simulator/.meta Expand file tree Collapse file tree 1 file changed +22
-0
lines changed Original file line number Diff line number Diff line change 1+ { { func sut
2+ $" new RobotSimulator({enum $0.direction " Direction" }, {$0.position.x}, {$0.position.y})"
3+ end } }
4+
5+ using Xunit;
6+
7+ public class { { testClass } }
8+ {
9+ {{- for test in tests } }
10+ [Fact{ { if ! for.first } }(Skip = "Remove this Skip property to run this test"){ { end } }]
11+ public void { { test.testMethod } }()
12+ {
13+ var sut = {{ test.input | sut } };
14+ { {- if test.property == " move" } }
15+ sut.Move({ { test.input.instructions | string.literal } });
16+ { {- end } }
17+ Assert.Equal({ { test.expected.direction | enum " Direction" } }, sut.Direction);
18+ Assert.Equal({ { test.expected.position.x } }, sut.X);
19+ Assert.Equal({ { test.expected.position.y } }, sut.Y);
20+ }
21+ { { end -} }
22+ }
You can’t perform that action at this time.
0 commit comments