diff options
author | Bryan Bishop <kanzure@gmail.com> | 2013-08-04 15:59:16 -0500 |
---|---|---|
committer | Bryan Bishop <kanzure@gmail.com> | 2013-08-04 15:59:16 -0500 |
commit | a1bfc404cbf536b4d52db7792847613bfd050714 (patch) | |
tree | 00cf02f780baba6a26955c1f139c8a965093d67d /tests/tests.py | |
parent | dbf6c1eedca7502a065b3b1076180f9ed60992ed (diff) |
make isolate_incbins not take a global asm
Why on earth was this using globals?
Diffstat (limited to 'tests/tests.py')
-rw-r--r-- | tests/tests.py | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/tests/tests.py b/tests/tests.py index 8430eb6..79af902 100644 --- a/tests/tests.py +++ b/tests/tests.py @@ -445,12 +445,11 @@ class TestAsmList(unittest.TestCase): os.system("rm " + filename) def test_isolate_incbins(self): - global asm asm = ["123", "456", "789", "abc", "def", "ghi", 'INCBIN "baserom.gbc",$12DA,$12F8 - $12DA', "jkl", 'INCBIN "baserom.gbc",$137A,$13D0 - $137A'] - lines = isolate_incbins() + lines = isolate_incbins(asm=asm) self.assertIn(asm[6], lines) self.assertIn(asm[8], lines) for line in lines: @@ -489,7 +488,7 @@ class TestAsmList(unittest.TestCase): asm = ['first line', 'second line', 'third line', 'INCBIN "baserom.gbc",$90,$200 - $90', 'fifth line', 'last line'] - isolate_incbins() + isolate_incbins(asm=asm) process_incbins() line_num = find_incbin_to_replace_for(0x100) # must be the 4th line (the INBIN line) @@ -504,7 +503,7 @@ class TestAsmList(unittest.TestCase): asm = ['first line', 'second line', 'third line', 'INCBIN "baserom.gbc",$90,$200 - $90', 'fifth line', 'last line'] - isolate_incbins() + isolate_incbins(asm=asm) process_incbins() content = split_incbin_line_into_three(3, 0x100, 10) # must end up with three INCBINs in output @@ -517,7 +516,7 @@ class TestAsmList(unittest.TestCase): 'INCBIN "baserom.gbc",$90,$200 - $90', 'fifth line', 'last line', 'INCBIN "baserom.gbc",$33F,$4000 - $33F'] - isolate_incbins() + isolate_incbins(asm=asm) process_incbins() largest = analyze_intervals() self.assertEqual(largest[0]["line_number"], 6) |