diff options
author | Martin Vilcans <martin@librador.com> | 2012-02-01 20:24:25 +0100 |
---|---|---|
committer | Martin Vilcans <martin@librador.com> | 2012-02-01 20:26:46 +0100 |
commit | 77940d45a14a727250aa9117b85f716a249c5ad6 (patch) | |
tree | 6312c92989a268fd8d71383232b1fe6656d9a61d /tests/spmd_test.py | |
parent | 2bde078e4b5e8328a3a92f1e9b3b590469be9312 (diff) | |
download | screenplain-77940d45a14a727250aa9117b85f716a249c5ad6.tar.gz |
New syntax for dual dialog: ^ (Jan 2012 spec)
Diffstat (limited to 'tests/spmd_test.py')
-rw-r--r-- | tests/spmd_test.py | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/tests/spmd_test.py b/tests/spmd_test.py index aba2e84..264995b 100644 --- a/tests/spmd_test.py +++ b/tests/spmd_test.py @@ -128,8 +128,8 @@ class ParseTests(unittest2.TestCase): paras = list(parse([ 'BRICK', 'Fuck retirement.', - '||', - 'STEEL', + '', + 'STEEL ^', 'Fuck retirement!', ])) self.assertEquals([DualDialog], [type(p) for p in paras]) @@ -145,18 +145,18 @@ class ParseTests(unittest2.TestCase): dual.right.blocks ) - def test_dual_dialog_with_empty_right_dialog_is_ordinary_dialog(self): + def test_dual_dialog_without_previous_dialog_is_ignored(self): paras = list(parse([ - 'BRICK', + 'Brick strolls down the street.', + '', + 'BRICK ^', 'Nice retirement.', - '||', ])) - self.assertEquals([Dialog], [type(p) for p in paras]) - dialog = paras[0] - self.assertEqual(plain('BRICK'), dialog.character) + self.assertEquals([Action, Dialog], [type(p) for p in paras]) + dialog = paras[1] + self.assertEqual(plain('BRICK ^'), dialog.character) self.assertEqual([ - (False, plain('Nice retirement.')), - (False, plain('||')) + (False, plain('Nice retirement.')) ], dialog.blocks) def test_standard_transition(self): |