mirror of
https://github.com/mnaberez/py65.git
synced 2025-01-16 18:33:00 +00:00
Fix tests that broke when register display logic changed
This commit is contained in:
parent
1c6494f55f
commit
5adeb310d7
@ -786,7 +786,7 @@ class MonitorTests(unittest.TestCase):
|
|||||||
mon.onecmd('~ $10')
|
mon.onecmd('~ $10')
|
||||||
out = stdout.getvalue()
|
out = stdout.getvalue()
|
||||||
expected = "+16\n$10\n0020\n00010000\n"
|
expected = "+16\n$10\n0020\n00010000\n"
|
||||||
self.assertEqual(expected, out)
|
self.assertTrue(out.startswith(expected))
|
||||||
|
|
||||||
def test_tilde_shortcut_without_space_for_vice_compatibility(self):
|
def test_tilde_shortcut_without_space_for_vice_compatibility(self):
|
||||||
stdout = StringIO()
|
stdout = StringIO()
|
||||||
@ -794,7 +794,7 @@ class MonitorTests(unittest.TestCase):
|
|||||||
mon.onecmd('~$10')
|
mon.onecmd('~$10')
|
||||||
out = stdout.getvalue()
|
out = stdout.getvalue()
|
||||||
expected = "+16\n$10\n0020\n00010000\n"
|
expected = "+16\n$10\n0020\n00010000\n"
|
||||||
self.assertEqual(expected, out)
|
self.assertTrue(out.startswith(expected))
|
||||||
|
|
||||||
def test_do_tilde(self):
|
def test_do_tilde(self):
|
||||||
stdout = StringIO()
|
stdout = StringIO()
|
||||||
@ -802,14 +802,15 @@ class MonitorTests(unittest.TestCase):
|
|||||||
mon.do_tilde('$10')
|
mon.do_tilde('$10')
|
||||||
out = stdout.getvalue()
|
out = stdout.getvalue()
|
||||||
expected = "+16\n$10\n0020\n00010000\n"
|
expected = "+16\n$10\n0020\n00010000\n"
|
||||||
self.assertEqual(expected, out)
|
self.assertTrue(out.startswith(expected))
|
||||||
|
|
||||||
def test_help_tilde(self):
|
def test_help_tilde(self):
|
||||||
stdout = StringIO()
|
stdout = StringIO()
|
||||||
mon = Monitor(stdout=stdout)
|
mon = Monitor(stdout=stdout)
|
||||||
mon.help_tilde()
|
mon.help_tilde()
|
||||||
out = stdout.getvalue()
|
out = stdout.getvalue()
|
||||||
self.assertTrue(out.startswith("~ <number>"))
|
expected = "~ <number>"
|
||||||
|
self.assertTrue(out.startswith(expected))
|
||||||
|
|
||||||
# show_labels
|
# show_labels
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user