Skip to content

Commit

Permalink
use virtual_machine_by_boards
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian-B committed Apr 9, 2024
1 parent 78b6275 commit 340ff52
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions unittests/test_json_machine.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,14 @@ def test_exceptions(self):
self.assertEqual(vchip33.tag_ids, chip33.tag_ids)

def test_monitor_exceptions(self):
vm = virtual_machine(width=8, height=8)
vm = virtual_machine_by_boards(1)
MachineDataWriter.mock().set_machine(vm)
chip02 = vm[0, 2]
for chip in vm.chips:
if chip.ip_address is None:
break
# Hack in an extra monitor
chip02._scamp_processors = tuple([0, 1])
chip02._placable_processors = tuple([2, 3, 4, 5, 6, 7, 8, 9])
chip._scamp_processors = tuple([0, 1])
chip._placable_processors = tuple([2, 3, 4, 5, 6, 7, 8, 9])
jpath = mktemp("json")
# Should still be able to write json even with more than one monitor
to_json_path(jpath)
Expand Down

0 comments on commit 340ff52

Please sign in to comment.