def test_get_track_single(self): # get track when only track t = Track(0) ts = TrackSet([t]) u = ts.get_track(0) # Check that they're the same underlying instance nt.assert_equal(ctypes.addressof(t.c_pointer.contents), ctypes.addressof(u.c_pointer.contents))
def test_get_track_multiple(self): n = 10 tracks = [Track(i) for i in range(n)] ts = TrackSet(tracks) # Check that they're the same underlying instance for i in range(n): nt.assert_equal( ctypes.addressof(ts.get_track(i).c_pointer.contents), ctypes.addressof(tracks[i].c_pointer.contents))
def test_get_track_single(self): # get track when only track t = Track(0) ts = TrackSet([t]) u = ts.get_track(0)