main
1using developwithpassion.bdd.contexts;
2using developwithpassion.bdd.mbunit;
3using developwithpassion.bdd.mbunit.standard.observations;
4using mars.rover.domain;
5
6namespace specifications.domain
7{
8 public class MarsSpecs
9 {
10 }
11
12 public class when_within_the_x_boundary : observations_for_a_sut_without_a_contract<Mars>
13 {
14 it should_return_true = () => result.should_be_true();
15
16 because b = () => { result = sut.within_x_axis(3); };
17
18 public override Mars create_sut()
19 {
20 return new Mars(3, 3);
21 }
22
23 static bool result;
24 }
25
26 public class when_within_the_y_boundary : observations_for_a_sut_without_a_contract<Mars>
27 {
28 it should_return_true = () => result.should_be_true();
29
30 because b = () => { result = sut.within_y_axis(3); };
31
32 public override Mars create_sut()
33 {
34 return new Mars(3, 3);
35 }
36
37 static bool result;
38 }
39
40 public class when_outside_the_y_boundary : observations_for_a_sut_without_a_contract<Mars>
41 {
42 it should_return_false = () => result.should_be_false();
43
44 because b = () => { result = sut.within_y_axis(4); };
45
46 public override Mars create_sut()
47 {
48 return new Mars(3, 3);
49 }
50
51 static bool result;
52 }
53
54 public class when_outside_the_x_boundary : observations_for_a_sut_without_a_contract<Mars>
55 {
56 it should_return_false = () => result.should_be_false();
57
58 because b = () => { result = sut.within_x_axis(4); };
59
60 public override Mars create_sut()
61 {
62 return new Mars(3, 3);
63 }
64
65 static bool result;
66 }
67}