mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-28 03:00:35 +00:00
GESSimpleTimelineLayer: add test for _nth() method
This commit is contained in:
parent
c60a4b5734
commit
4dae5c83f4
1 changed files with 10 additions and 0 deletions
|
@ -66,6 +66,7 @@ GST_START_TEST (test_gsl_add)
|
|||
GESTimelineLayer *layer;
|
||||
GESTrack *track;
|
||||
GESCustomTimelineSource *source;
|
||||
GESTimelineObject *source2;
|
||||
|
||||
ges_init ();
|
||||
/* This is the simplest scenario ever */
|
||||
|
@ -90,6 +91,15 @@ GST_START_TEST (test_gsl_add)
|
|||
fail_unless_equals_uint64 (GES_TIMELINE_OBJECT_DURATION (source), GST_SECOND);
|
||||
fail_unless_equals_uint64 (GES_TIMELINE_OBJECT_START (source), 0);
|
||||
|
||||
/* test nth */
|
||||
source2 =
|
||||
ges_simple_timeline_layer_nth ((GESSimpleTimelineLayer *) layer, -1);
|
||||
fail_if (source2);
|
||||
source2 = ges_simple_timeline_layer_nth ((GESSimpleTimelineLayer *) layer, 2);
|
||||
fail_if (source2);
|
||||
source2 = ges_simple_timeline_layer_nth ((GESSimpleTimelineLayer *) layer, 0);
|
||||
fail_unless ((GESTimelineObject *) source == source2);
|
||||
|
||||
fail_unless (ges_timeline_layer_remove_object (layer,
|
||||
GES_TIMELINE_OBJECT (source)));
|
||||
fail_unless (ges_timeline_remove_track (timeline, track));
|
||||
|
|
Loading…
Reference in a new issue