Beispiel #1
0
 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))
Beispiel #2
0
    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))
Beispiel #3
0
 def test_get_track_single(self):
     # get track when only track
     t = Track(0)
     ts = TrackSet([t])
     u = ts.get_track(0)