1
1
import org .scalatest .{Matchers , FunSuite }
2
2
3
- /** @version 1.2 .0 */
3
+ /** @version 1.4 .0 */
4
4
class BobTest extends FunSuite with Matchers {
5
5
6
-
7
6
test(" stating something" ) {
8
- Bob .response(" Tom-ay-to, tom-aaaah-to." ) should be (" Whatever." )
7
+ Bob .response(" Tom-ay-to, tom-aaaah-to." ) should be(" Whatever." )
9
8
}
10
9
11
10
test(" shouting" ) {
12
11
pending
13
- Bob .response(" WATCH OUT!" ) should be (" Whoa, chill out!" )
12
+ Bob .response(" WATCH OUT!" ) should be(" Whoa, chill out!" )
14
13
}
15
14
16
15
test(" shouting gibberish" ) {
17
16
pending
18
- Bob .response(" FCECDFCAAB" ) should be (" Whoa, chill out!" )
17
+ Bob .response(" FCECDFCAAB" ) should be(" Whoa, chill out!" )
19
18
}
20
19
21
20
test(" asking a question" ) {
22
21
pending
23
- Bob .response(" Does this cryogenic chamber make me look fat?" ) should be (" Sure." )
22
+ Bob .response(" Does this cryogenic chamber make me look fat?" ) should be(
23
+ " Sure." )
24
24
}
25
25
26
26
test(" asking a numeric question" ) {
27
27
pending
28
- Bob .response(" You are, what, like 15?" ) should be (" Sure." )
28
+ Bob .response(" You are, what, like 15?" ) should be(" Sure." )
29
29
}
30
30
31
31
test(" asking gibberish" ) {
32
32
pending
33
- Bob .response(" fffbbcbeab?" ) should be (" Sure." )
33
+ Bob .response(" fffbbcbeab?" ) should be(" Sure." )
34
34
}
35
35
36
36
test(" talking forcefully" ) {
37
37
pending
38
- Bob .response(" Let's go make out behind the gym!" ) should be (" Whatever." )
38
+ Bob .response(" Let's go make out behind the gym!" ) should be(" Whatever." )
39
39
}
40
40
41
41
test(" using acronyms in regular speech" ) {
42
42
pending
43
- Bob .response(" It's OK if you don't want to go to the DMV." ) should be (" Whatever." )
43
+ Bob .response(" It's OK if you don't want to go to the DMV." ) should be(
44
+ " Whatever." )
44
45
}
45
46
46
47
test(" forceful question" ) {
47
48
pending
48
- Bob .response(" WHAT THE HELL WERE YOU THINKING?" ) should be (" Calm down, I know what I'm doing!" )
49
+ Bob .response(" WHAT THE HELL WERE YOU THINKING?" ) should be(
50
+ " Calm down, I know what I'm doing!" )
49
51
}
50
52
51
53
test(" shouting numbers" ) {
52
54
pending
53
- Bob .response(" 1, 2, 3 GO!" ) should be (" Whoa, chill out!" )
55
+ Bob .response(" 1, 2, 3 GO!" ) should be(" Whoa, chill out!" )
54
56
}
55
57
56
- test(" only numbers " ) {
58
+ test(" no letters " ) {
57
59
pending
58
- Bob .response(" 1, 2, 3" ) should be (" Whatever." )
60
+ Bob .response(" 1, 2, 3" ) should be(" Whatever." )
59
61
}
60
62
61
- test(" question with only numbers " ) {
63
+ test(" question with no letters " ) {
62
64
pending
63
- Bob .response(" 4?" ) should be (" Sure." )
65
+ Bob .response(" 4?" ) should be(" Sure." )
64
66
}
65
67
66
68
test(" shouting with special characters" ) {
67
69
pending
68
- Bob .response(" ZOMG THE %^*@#$(*^ ZOMBIES ARE COMING!!11!!1!" ) should be (" Whoa, chill out!" )
70
+ Bob .response(" ZOMG THE %^*@#$(*^ ZOMBIES ARE COMING!!11!!1!" ) should be(
71
+ " Whoa, chill out!" )
69
72
}
70
73
71
74
test(" shouting with no exclamation mark" ) {
72
75
pending
73
- Bob .response(" I HATE YOU " ) should be (" Whoa, chill out!" )
76
+ Bob .response(" I HATE THE DMV " ) should be(" Whoa, chill out!" )
74
77
}
75
78
76
79
test(" statement containing question mark" ) {
77
80
pending
78
- Bob .response(" Ending with ? means a question." ) should be (" Whatever." )
81
+ Bob .response(" Ending with ? means a question." ) should be(" Whatever." )
79
82
}
80
83
81
84
test(" non-letters with question" ) {
82
85
pending
83
- Bob .response(" :) ?" ) should be (" Sure." )
86
+ Bob .response(" :) ?" ) should be(" Sure." )
84
87
}
85
88
86
89
test(" prattling on" ) {
87
90
pending
88
- Bob .response(" Wait! Hang on. Are you going to be OK?" ) should be (" Sure." )
91
+ Bob .response(" Wait! Hang on. Are you going to be OK?" ) should be(" Sure." )
89
92
}
90
93
91
94
test(" silence" ) {
92
95
pending
93
- Bob .response(" " ) should be (" Fine. Be that way!" )
96
+ Bob .response(" " ) should be(" Fine. Be that way!" )
94
97
}
95
98
96
99
test(" prolonged silence" ) {
97
100
pending
98
- Bob .response(" " ) should be (" Fine. Be that way!" )
101
+ Bob .response(" " ) should be(" Fine. Be that way!" )
99
102
}
100
103
101
104
test(" alternate silence" ) {
102
105
pending
103
- Bob .response(" " ) should be (" Fine. Be that way!" )
106
+ Bob .response(" " ) should be(" Fine. Be that way!" )
104
107
}
105
108
106
109
test(" multiple line question" ) {
107
110
pending
108
111
Bob .response("""
109
112
Does this cryogenic chamber make me look fat?
110
- no """ ) should be (" Whatever." )
113
+ No. """ ) should be(" Whatever." )
111
114
}
112
115
113
116
test(" starting with whitespace" ) {
114
117
pending
115
- Bob .response(" hmmmmmmm..." ) should be (" Whatever." )
118
+ Bob .response(" hmmmmmmm..." ) should be(" Whatever." )
116
119
}
117
120
118
121
test(" ending with whitespace" ) {
119
122
pending
120
- Bob .response(" Okay if like my spacebar quite a bit? " ) should be (" Sure." )
123
+ Bob .response(" Okay if like my spacebar quite a bit? " ) should be(
124
+ " Sure." )
121
125
}
122
126
123
127
test(" other whitespace" ) {
124
128
pending
125
129
Bob .response("""
126
- """ ) should be (" Fine. Be that way!" )
130
+ """ ) should be(" Fine. Be that way!" )
127
131
}
128
132
129
133
test(" non-question ending with whitespace" ) {
130
134
pending
131
- Bob .response(" This is a statement ending with whitespace " ) should be (" Whatever." )
135
+ Bob .response(" This is a statement ending with whitespace " ) should be(
136
+ " Whatever." )
132
137
}
133
- }
138
+ }
0 commit comments