Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def __init__(self, expected_value):
_ScalarMatcher.__init__(self, _visatype.ViUInt32, expected_value)
def __init__(self, expected_size_or_value):
_BufferMatcher.__init__(self, _visatype.ViChar, expected_size_or_value)
def test_convert_timedelta_to_milliseconds_int():
test_result = convert_timedelta_to_milliseconds(datetime.timedelta(seconds=10), _visatype.ViInt32)
assert test_result.value == 10000
assert isinstance(test_result, _visatype.ViInt32)
test_result = convert_timedelta_to_milliseconds(datetime.timedelta(seconds=-1), _visatype.ViInt32)
assert test_result.value == -1000
assert isinstance(test_result, _visatype.ViInt32)
test_result = convert_timedelta_to_milliseconds(10.5, _visatype.ViInt32)
assert test_result.value == 10500
assert isinstance(test_result, _visatype.ViInt32)
test_result = convert_timedelta_to_milliseconds(-1, _visatype.ViInt32)
assert test_result.value == -1000
assert isinstance(test_result, _visatype.ViInt32)