def test_offset_zero(): a = Wire(1, 2, 0.5) assert a.offset(1, 2) == approx(0)
def test_offset(): a = Wire(1, 1, 0.5) assert a.offset() == approx(np.sqrt(2))