MCPcopy Create free account
hub / github.com/ActiveState/code / check

Function check

recipes/Python/577191_IP_and_MAC_addresses/recipe-577191.py:797–804  ·  view source on GitHub ↗
(value, *expected)

Source from the content-addressed store, hash-verified

795 e = t = 0
796
797 def check(value, *expected):
798 global e, t
799 t += 1
800 if value not in expected:
801 x = ', '.join([repr(x) for x in expected])
802 printf('%s error: %r, expected %s',
803 n, value, x)
804 e += 1
805
806 s = gets()
807 printf('get%ss(): %r', n, s)

Callers 1

testFunction · 0.70

Calls 2

printfFunction · 0.70
joinMethod · 0.45

Tested by

no test coverage detected