Skip to content

Commit

Permalink
Disable interrupts where appropriate in trace.py tests
Browse files Browse the repository at this point in the history
  • Loading branch information
skoolkid committed Sep 12, 2024
1 parent 3714592 commit 88b61dc
Showing 1 changed file with 11 additions and 11 deletions.
22 changes: 11 additions & 11 deletions tests/test_trace.py
Original file line number Diff line number Diff line change
Expand Up @@ -1060,7 +1060,7 @@ def test_option_audio(self):
]
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32776
output, error = self.run_trace(f'-o {start} -S {stop} --audio {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $8008
Expand All @@ -1082,7 +1082,7 @@ def test_option_audio_with_delays_over_multiple_lines(self):
)
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32780
output, error = self.run_trace(f'-o {start} -S {stop} --audio {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $800C
Expand Down Expand Up @@ -1229,7 +1229,7 @@ def test_option_depth_0(self):
)
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32776
output, error = self.run_trace(f'-o {start} -S {stop} --audio --depth 0 {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio --depth 0 {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $8008
Expand All @@ -1248,7 +1248,7 @@ def test_option_depth_1(self):
)
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32776
output, error = self.run_trace(f'-o {start} -S {stop} --audio --depth 1 {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio --depth 1 {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $8008
Expand All @@ -1269,7 +1269,7 @@ def test_option_depth_2(self):
)
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32780
output, error = self.run_trace(f'-o {start} -S {stop} --audio --depth 2 {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio --depth 2 {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $800C
Expand All @@ -1292,7 +1292,7 @@ def test_option_depth_3(self):
)
binfile = self.write_bin_file(data, suffix='.bin')
start, stop = 32768, 32784
output, error = self.run_trace(f'-o {start} -S {stop} --audio --depth 3 {binfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} --audio --depth 3 {binfile}')
self.assertEqual(error, '')
exp_output = """
Stopped at $8010
Expand Down Expand Up @@ -2064,7 +2064,7 @@ def test_config_PNGScale_read_from_file(self):
outfile = 'out.png'
start = 32768
stop = start + len(data)
output, error = self.run_trace(f'-o {start} -S {stop} {infile} {outfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} {infile} {outfile}')
exp_output = f"""
Stopped at ${stop:04X}
Wrote {outfile}
Expand All @@ -2090,7 +2090,7 @@ def test_config_PNGScale_set_on_command_line(self):
outfile = 'out.png'
start = 32768
stop = start + len(data)
output, error = self.run_trace(f'-I PNGScale=3 -o {start} -S {stop} {infile} {outfile}')
output, error = self.run_trace(f'-n -I PNGScale=3 -o {start} -S {stop} {infile} {outfile}')
exp_output = f"""
Stopped at ${stop:04X}
Wrote {outfile}
Expand Down Expand Up @@ -2812,7 +2812,7 @@ def test_write_png(self):
outfile = 'out.png'
start = 32768
stop = start + len(data)
output, error = self.run_trace(f'-o {start} -S {stop} {infile} {outfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} {infile} {outfile}')
exp_output = f"""
Stopped at ${stop:04X}
Wrote {outfile}
Expand Down Expand Up @@ -2852,7 +2852,7 @@ def test_write_wav_48k(self):
outfile = 'out.wav'
start = 32768
stop = start + len(data)
output, error = self.run_trace(f'-o {start} -S {stop} {infile} {outfile}')
output, error = self.run_trace(f'-n -o {start} -S {stop} {infile} {outfile}')
exp_output = f"""
Stopped at ${stop:04X}
Wrote {outfile}
Expand Down Expand Up @@ -2902,7 +2902,7 @@ def test_write_wav_no_audio(self):
start = 32768
stop = start + len(data)
with self.assertRaises(SkoolKitError) as cm:
self.run_trace(f'-o {start} -S {stop} {infile} out.wav')
self.run_trace(f'-n -o {start} -S {stop} {infile} out.wav')
self.assertEqual(cm.exception.args[0], 'No audio detected')
self.assertIsNone(audio_writer)

Expand Down

0 comments on commit 88b61dc

Please sign in to comment.