python: Avoid warning about using deprecated methods

Fixes https://gitlab.freedesktop.org/gstreamer/gst-editing-services/issues/69
This commit is contained in:
Thibault Saunier 2019-05-04 10:47:07 -04:00
parent d87578c843
commit 4ded3b8838
2 changed files with 10 additions and 1 deletions

View file

@ -70,7 +70,7 @@ class TimelineElement(GES.TimelineElement):
)
def set_child_property(self, prop_name, prop_value):
res, child, unused_pspec = self.lookup_child(prop_name)
res, child, unused_pspec = GES.TimelineElement.lookup_child(self, prop_name)
if not res:
return res

View file

@ -935,3 +935,12 @@ class TestPriorities(common.GESSimpleTimelineTest):
clip.props.start = 101
self.timeline.commit()
self.assertGreater(clip.props.priority, clip1.props.priority)
class TestTimelineElement(common.GESSimpleTimelineTest):
def test_set_child_property(self):
clip = self.add_clip(0, 0, 100)
source = clip.find_track_element(None, GES.VideoSource)
self.assertTrue(source.set_child_property("height", 5))
self.assertEqual(clip.get_child_property("height"), (True, 5))