aboutsummaryrefslogtreecommitdiff
path: root/nixpkgs/pkgs/development/libraries/gstreamer/legacy/gst-python/disable-testFake.patch
blob: d0c9960e5d22190e7a55a480fe110bfc5a0e92e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
diff -Nurp gst-python-0.10.22.orig/testsuite/test_bin.py gst-python-0.10.22/testsuite/test_bin.py
--- gst-python-0.10.22.orig/testsuite/test_bin.py	2014-10-29 18:58:00.921827721 +0100
+++ gst-python-0.10.22/testsuite/test_bin.py	2014-10-29 19:00:32.019353092 +0100
@@ -131,52 +131,6 @@ class BinAddRemove(TestCase):
         self.assertRaises(gst.AddError, self.bin.add, src, sink)
         self.bin.remove(src, sink)
         self.assertRaises(gst.RemoveError, self.bin.remove, src, sink)
-
-class Preroll(TestCase):
-    def setUp(self):
-        TestCase.setUp(self)
-        self.bin = gst.Bin('bin')
-
-    def tearDown(self):
-        # FIXME: wait for state change thread to settle down
-        while self.bin.__gstrefcount__ > 1:
-            time.sleep(0.1)
-        self.assertEquals(self.bin.__gstrefcount__, 1)
-        del self.bin
-        TestCase.tearDown(self)
-
-    def testFake(self):
-        src = gst.element_factory_make('fakesrc')
-        sink = gst.element_factory_make('fakesink')
-        self.bin.add(src)
-
-        # bin will go to paused, src pad task will start and error out
-        self.bin.set_state(gst.STATE_PAUSED)
-        ret = self.bin.get_state()
-        self.assertEquals(ret[0], gst.STATE_CHANGE_SUCCESS)
-        self.assertEquals(ret[1], gst.STATE_PAUSED)
-        self.assertEquals(ret[2], gst.STATE_VOID_PENDING)
-
-        # adding the sink will cause the bin to go in preroll mode
-        gst.debug('adding sink and setting to PAUSED, should cause preroll')
-        self.bin.add(sink)
-        sink.set_state(gst.STATE_PAUSED)
-        ret = self.bin.get_state(timeout=0)
-        self.assertEquals(ret[0], gst.STATE_CHANGE_ASYNC)
-        self.assertEquals(ret[1], gst.STATE_PAUSED)
-        self.assertEquals(ret[2], gst.STATE_PAUSED)
-
-        # to actually complete preroll, we need to link and re-enable fakesrc
-        src.set_state(gst.STATE_READY)
-        src.link(sink)
-        src.set_state(gst.STATE_PAUSED)
-        ret = self.bin.get_state()
-        self.assertEquals(ret[0], gst.STATE_CHANGE_SUCCESS)
-        self.assertEquals(ret[1], gst.STATE_PAUSED)
-        self.assertEquals(ret[2], gst.STATE_VOID_PENDING)
-
-        self.bin.set_state(gst.STATE_NULL)
-        self.bin.get_state()
  
 class ConstructorTest(TestCase):
     def testGood(self):