[pitivi] tests/test_integration.py: track transitions in InstanceRunner



commit 33835016f7cf322b637eeb338798514382ab2b39
Author: Brandon Lewis <brandon_lewis alum berkeley edu>
Date:   Fri Mar 5 23:48:10 2010 -0800

    tests/test_integration.py: track transitions in InstanceRunner

 tests/test_integration.py |   10 ++++++++++
 1 files changed, 10 insertions(+), 0 deletions(-)
---
diff --git a/tests/test_integration.py b/tests/test_integration.py
index fa59491..810cf7c 100644
--- a/tests/test_integration.py
+++ b/tests/test_integration.py
@@ -263,6 +263,16 @@ class InstanceRunner(Signallable):
         container = self.container()
         setattr(self, attrname, container)
         self.tracks[track] = container 
+        container.transitions = {}
+        track.connect("transition-added", self._transitionAddedCb, container)
+        track.connect("transition-removed", self._transitionRemovedCb,
+            container)
+
+    def _transitionAddedCb(self, track, transition, container):
+        container.transitions[(transition.a, transition.b)] = transition
+
+    def _transitionRemovedCb(self, track, transition, container):
+        del container.transitions[(transition.a, transition.b)]
 
     def _setupTimeline(self, configuration):
         for name, uri, props in configuration:



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]