projects
/
mudpy.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Test implicit punctuation
[mudpy.git]
/
bin
/
test
diff --git
a/bin/test
b/bin/test
index
35b2a99
..
181ea0a
100755
(executable)
--- a/
bin/test
+++ b/
bin/test
@@
-53,6
+53,11
@@
dialogue = (
(1, 'You begin, "I wasn\'t interrupting;"', ""),
(0, 'begins, "I wasn\'t interrupting;"', ""),
(1, 'You begin, "I wasn\'t interrupting;"', ""),
(0, 'begins, "I wasn\'t interrupting;"', ""),
+ # Implicit punctuation
+ (0, '> ', "say Whatever"),
+ (0, 'You say, "Whatever."', ""),
+ (1, 'says, "Whatever."', ""),
+
# Actor disappears
(1, "> ", "quit"),
(0, "You suddenly wonder where .* went\.", ""),
# Actor disappears
(1, "> ", "quit"),
(0, "You suddenly wonder where .* went\.", ""),
@@
-85,6
+90,11
@@
for conversant, question, answer in dialogue:
index, match, received = lusers[conversant].expect(
[question.encode("utf-8")], 5)
captures[conversant] += received.decode("utf-8")
index, match, received = lusers[conversant].expect(
[question.encode("utf-8")], 5)
captures[conversant] += received.decode("utf-8")
+ try:
+ captures[conversant] += lusers[
+ conversant].read_very_eager().decode("utf-8")
+ except:
+ pass
if index is not 0:
print("ERROR: luser%s did not receive expected string:\n\n%s"
% (conversant, question))
if index is not 0:
print("ERROR: luser%s did not receive expected string:\n\n%s"
% (conversant, question))