Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def test_channel_format_types():
with nifgen.Session('', [0, 1], False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', range(2), False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', '0,1', False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', None, False, 'Simulate=1, DriverSetup=Model:5433 (2CH); BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session(resource_name='', reset_device=False, options='Simulate=1, DriverSetup=Model:5433 (2CH); BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
def test_channel_format_types():
with nifgen.Session('', [0, 1], False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', range(2), False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', '0,1', False, 'Simulate=1, DriverSetup=Model:5433 (2CH);BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session('', None, False, 'Simulate=1, DriverSetup=Model:5433 (2CH); BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
with nifgen.Session(resource_name='', reset_device=False, options='Simulate=1, DriverSetup=Model:5433 (2CH); BoardType:PXIe') as simulated_session:
assert simulated_session.channel_count == 2
def __init__(self, expected_size_or_value):
_BufferMatcher.__init__(self, _visatype.ViBoolean, expected_size_or_value)
def __init__(self):
_PointerMatcher.__init__(self, _visatype.ViInt32)
def __init__(self, expected_size_or_value):
_BufferMatcher.__init__(self, _visatype.ViInt8, expected_size_or_value)
def __init__(self):
_PointerMatcher.__init__(self, _visatype.ViReal64)
def __init__(self, expected_value):
_ScalarMatcher.__init__(self, _visatype.ViInt16, expected_value)
def __init__(self):
_PointerMatcher.__init__(self, _visatype.ViSession)
def __init__(self, expected_size_or_value):
_BufferMatcher.__init__(self, _visatype.ViReal64, expected_size_or_value)
def __init__(self):
_PointerMatcher.__init__(self, _visatype.ViInt32)