-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: Mock modules as well, since strictly required
- Loading branch information
1 parent
83160f6
commit d79ebc6
Showing
1 changed file
with
28 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,40 @@ | ||
__all__ = [] | ||
|
||
|
||
class MockModule: | ||
def __init__(self, slot: int) -> None: | ||
self.slot_idx = slot | ||
|
||
def present(self) -> bool: | ||
return True | ||
|
||
@property | ||
def is_qrm_type(self) -> bool: | ||
return True | ||
|
||
@property | ||
def sequencers(self) -> list: | ||
return [None] * 20 | ||
|
||
def disconnect_outputs(self) -> None: | ||
pass | ||
|
||
def scope_acq_trigger_mode_path0(self, mode: str) -> None: | ||
pass | ||
|
||
def scope_acq_trigger_mode_path1(self, mode: str) -> None: | ||
pass | ||
|
||
|
||
class MockCluster: | ||
def __init__(self, *args, **kwargs) -> None: | ||
self.args = args | ||
self.kwargs = kwargs | ||
self.resets: int = 0 | ||
|
||
@property | ||
def modules(self): | ||
return [] | ||
def modules(self) -> list: | ||
return [MockModule(slot) for slot in range(21)] | ||
|
||
def reset(self): | ||
def reset(self) -> None: | ||
self.resets += 1 |