|
3 | 3 | [TestFixture] |
4 | 4 | public class BobTest |
5 | 5 | { |
6 | | - private Bob teenager; |
7 | | - |
8 | | - [SetUp] |
9 | | - public void Init () |
10 | | - { |
11 | | - teenager = new Bob(); |
12 | | - } |
13 | | - |
14 | 6 | [Test] |
15 | 7 | public void Stating_something () |
16 | 8 | { |
17 | | - Assert.That(teenager.Hey("Tom-ay-to, tom-aaaah-to."), Is.EqualTo("Whatever.")); |
| 9 | + Assert.That(Bob.Hey("Tom-ay-to, tom-aaaah-to."), Is.EqualTo("Whatever.")); |
18 | 10 | } |
19 | 11 |
|
20 | 12 | [Ignore] |
21 | 13 | [Test] |
22 | 14 | public void Shouting () |
23 | 15 | { |
24 | | - Assert.That(teenager.Hey("WATCH OUT!"), Is.EqualTo("Whoa, chill out!")); |
| 16 | + Assert.That(Bob.Hey("WATCH OUT!"), Is.EqualTo("Whoa, chill out!")); |
25 | 17 | } |
26 | 18 |
|
27 | 19 | [Ignore] |
28 | 20 | [Test] |
29 | 21 | public void Asking_a_question () |
30 | 22 | { |
31 | | - Assert.That(teenager.Hey("Does this cryogenic chamber make me look fat?"), Is.EqualTo("Sure.")); |
| 23 | + Assert.That(Bob.Hey("Does this cryogenic chamber make me look fat?"), Is.EqualTo("Sure.")); |
32 | 24 | } |
33 | 25 |
|
34 | 26 | [Ignore] |
35 | 27 | [Test] |
36 | 28 | public void Asking_a_question_with_a_trailing_space() |
37 | 29 | { |
38 | | - Assert.That(teenager.Hey("Do I like my spacebar too much? "), Is.EqualTo("Sure.")); |
| 30 | + Assert.That(Bob.Hey("Do I like my spacebar too much? "), Is.EqualTo("Sure.")); |
39 | 31 | } |
40 | 32 |
|
41 | 33 | [Ignore] |
42 | 34 | [Test] |
43 | 35 | public void Asking_a_numeric_question () |
44 | 36 | { |
45 | | - Assert.That(teenager.Hey("You are, what, like 15?"), Is.EqualTo("Sure.")); |
| 37 | + Assert.That(Bob.Hey("You are, what, like 15?"), Is.EqualTo("Sure.")); |
46 | 38 | } |
47 | 39 |
|
48 | 40 | [Ignore] |
49 | 41 | [Test] |
50 | 42 | public void Talking_forcefully () |
51 | 43 | { |
52 | | - Assert.That(teenager.Hey("Let's go make out behind the gym!"), Is.EqualTo("Whatever.")); |
| 44 | + Assert.That(Bob.Hey("Let's go make out behind the gym!"), Is.EqualTo("Whatever.")); |
53 | 45 | } |
54 | 46 |
|
55 | 47 | [Ignore] |
56 | 48 | [Test] |
57 | 49 | public void Using_acronyms_in_regular_search () |
58 | 50 | { |
59 | | - Assert.That(teenager.Hey("It's OK if you don't want to go to the DMV."), Is.EqualTo("Whatever.")); |
| 51 | + Assert.That(Bob.Hey("It's OK if you don't want to go to the DMV."), Is.EqualTo("Whatever.")); |
60 | 52 | } |
61 | 53 |
|
62 | 54 | [Ignore] |
63 | 55 | [Test] |
64 | 56 | public void Forceful_questions () |
65 | 57 | { |
66 | | - Assert.That(teenager.Hey("WHAT THE HELL WERE YOU THINKING?"), Is.EqualTo("Whoa, chill out!")); |
| 58 | + Assert.That(Bob.Hey("WHAT THE HELL WERE YOU THINKING?"), Is.EqualTo("Whoa, chill out!")); |
67 | 59 | } |
68 | 60 |
|
69 | 61 | [Ignore] |
70 | 62 | [Test] |
71 | 63 | public void Shouting_numbers () |
72 | 64 | { |
73 | | - Assert.That(teenager.Hey("1, 2, 3 GO!"), Is.EqualTo("Whoa, chill out!")); |
| 65 | + Assert.That(Bob.Hey("1, 2, 3 GO!"), Is.EqualTo("Whoa, chill out!")); |
74 | 66 | } |
75 | 67 |
|
76 | 68 | [Ignore] |
77 | 69 | [Test] |
78 | 70 | public void Only_numbers () |
79 | 71 | { |
80 | | - Assert.That(teenager.Hey("1, 2, 3"), Is.EqualTo("Whatever.")); |
| 72 | + Assert.That(Bob.Hey("1, 2, 3"), Is.EqualTo("Whatever.")); |
81 | 73 | } |
82 | 74 |
|
83 | 75 | [Ignore] |
84 | 76 | [Test] |
85 | 77 | public void Question_with_only_numbers () |
86 | 78 | { |
87 | | - Assert.That(teenager.Hey("4?"), Is.EqualTo("Sure.")); |
| 79 | + Assert.That(Bob.Hey("4?"), Is.EqualTo("Sure.")); |
88 | 80 | } |
89 | 81 |
|
90 | 82 | [Ignore] |
91 | 83 | [Test] |
92 | 84 | public void Shouting_with_special_characters () |
93 | 85 | { |
94 | | - Assert.That(teenager.Hey("ZOMG THE %^*@#$(*^ ZOMBIES ARE COMING!!11!!1!"), Is.EqualTo("Whoa, chill out!")); |
| 86 | + Assert.That(Bob.Hey("ZOMG THE %^*@#$(*^ ZOMBIES ARE COMING!!11!!1!"), Is.EqualTo("Whoa, chill out!")); |
95 | 87 | } |
96 | 88 |
|
97 | 89 | [Ignore] |
98 | 90 | [Test] |
99 | 91 | public void Shouting_with_no_exclamation_mark () |
100 | 92 | { |
101 | | - Assert.That(teenager.Hey("I HATE YOU"), Is.EqualTo("Whoa, chill out!")); |
| 93 | + Assert.That(Bob.Hey("I HATE YOU"), Is.EqualTo("Whoa, chill out!")); |
102 | 94 | } |
103 | 95 |
|
104 | 96 | [Ignore] |
105 | 97 | [Test] |
106 | 98 | public void Statement_containing_question_mark () |
107 | 99 | { |
108 | | - Assert.That(teenager.Hey("Ending with ? means a question."), Is.EqualTo("Whatever.")); |
| 100 | + Assert.That(Bob.Hey("Ending with ? means a question."), Is.EqualTo("Whatever.")); |
109 | 101 | } |
110 | 102 |
|
111 | 103 | [Ignore] |
112 | 104 | [Test] |
113 | 105 | public void Prattling_on () |
114 | 106 | { |
115 | | - Assert.That(teenager.Hey("Wait! Hang on. Are you going to be OK?"), Is.EqualTo("Sure.")); |
| 107 | + Assert.That(Bob.Hey("Wait! Hang on. Are you going to be OK?"), Is.EqualTo("Sure.")); |
116 | 108 | } |
117 | 109 |
|
118 | 110 | [Ignore] |
119 | 111 | [Test] |
120 | 112 | public void Silence () |
121 | 113 | { |
122 | | - Assert.That(teenager.Hey(""), Is.EqualTo("Fine. Be that way!")); |
| 114 | + Assert.That(Bob.Hey(""), Is.EqualTo("Fine. Be that way!")); |
123 | 115 | } |
124 | 116 |
|
125 | 117 | [Ignore] |
126 | 118 | [Test] |
127 | 119 | public void Prolonged_silence () |
128 | 120 | { |
129 | | - Assert.That(teenager.Hey(" "), Is.EqualTo("Fine. Be that way!")); |
| 121 | + Assert.That(Bob.Hey(" "), Is.EqualTo("Fine. Be that way!")); |
130 | 122 | } |
131 | 123 |
|
132 | 124 | [Ignore] |
133 | 125 | [Test] |
134 | 126 | public void Multiple_line_question () |
135 | 127 | { |
136 | | - Assert.That(teenager.Hey("Does this cryogenic chamber make me look fat?\nno"), Is.EqualTo("Whatever.")); |
| 128 | + Assert.That(Bob.Hey("Does this cryogenic chamber make me look fat?\nno"), Is.EqualTo("Whatever.")); |
137 | 129 | } |
138 | 130 | } |
0 commit comments