mirror of
https://github.com/kk7ds/chirp.git
synced 2024-09-21 10:37:15 +00:00
Make assertEqualMem() ignore offset if duplex=off
If duplex is 'off' we don't need to obsess over the offset value, which is unused anyway. Some drivers may not be able to store an offset if duplex=off and/or may use the offset for signaling of that fact.
This commit is contained in:
parent
74a8717dc6
commit
985b78aa4f
@ -132,6 +132,14 @@ class DriverTest(unittest.TestCase):
|
||||
def assertEqualMem(self, a, b, ignore=None):
|
||||
if a.tmode == "Cross":
|
||||
tx_mode, rx_mode = a.cross_mode.split("->")
|
||||
if ignore is None:
|
||||
ignore = []
|
||||
|
||||
if a.duplex == b.duplex == 'off':
|
||||
# If we're asking for duplex=off, we should not obsess over the
|
||||
# driver keeping track of our offset, as it may use the offset
|
||||
# field to manage the TX behavior
|
||||
ignore.append('offset')
|
||||
|
||||
a_vals = {}
|
||||
b_vals = {}
|
||||
|
Loading…
Reference in New Issue
Block a user