Commit graph

24 commits

Author SHA1 Message Date
Antonio Ospite
1c5c90ea23 test: rtpbin_buffer_list: add a test for invalid packets in buffer list
Upstream elements can send all kinds of data in a buffer list, so cover
the case of an invalid RTP packet mixed with valid RTP packets.
2019-08-07 15:32:30 -04:00
Antonio Ospite
12b420168c test: rtpbin_buffer_list: add a test for multiplexed RTP and RTCP
RTP and RTCP packets can be muxed together on the same channel (see
RFC5761) and can arrive in the same buffer list.

The GStreamer rtpsession element support RFC5761, so add a test to cover
this case for buffer lists too.
2019-08-07 15:32:30 -04:00
Antonio Ospite
6a5f38a325 test: rtpbin_buffer_list: add a test for different timestamps in buffer list
Buffers with different timestamps (e.g. packets belonging to different
frames) can arrive together in the same buffer list,

Add a test to cover this case.
2019-08-07 15:32:30 -04:00
Antonio Ospite
b158be0d98 test: rtpbin_buffer_list: add function to check timestamp 2019-08-07 15:32:30 -04:00
Antonio Ospite
31f221f89d test: rtpbin_buffer_list: add a test about reordered or duplicated seqnums 2019-08-07 15:32:30 -04:00
Antonio Ospite
1d337b704e test: rtpbin_buffer_list: add a test for lange jump in seqnums with recovery 2019-08-07 15:32:30 -04:00
Antonio Ospite
ae5d4b8cf0 test: rtpbin_buffer_list: add a test for large jump in sequence numbers 2019-08-07 15:32:30 -04:00
Antonio Ospite
fb46c6bf08 test: rtpbin_buffer_list: add a test for wrapping sequence numbers 2019-08-07 15:32:30 -04:00
Antonio Ospite
d9d0461aeb test: rtpbin_buffer_list: add a test for permissible gap in sequence numbers 2019-08-07 15:32:30 -04:00
Antonio Ospite
92be4121e8 test: rtpbin_buffer_list: add a test for the case of failed probation
When a new source fails to pass the probation period (i.e. new packets
have non-consecutive sequence numbers), then no buffer shall be pushed
downstream. Add a test to validate this case.
2019-08-07 15:32:30 -04:00
Antonio Ospite
0537925c3a test: rtpbin_buffer_list: add function to check sequence number 2019-08-07 15:32:30 -04:00
Antonio Ospite
ec56e2fb78 test: rtpbin_buffer_list: add test to verify that receiving stats are correct
Add a test to verify that stats about received packets are correct when
using buffer lists in the rtpsession receive path.

Split get_session_source_stats() in two to be able to get stats from
a GstRtpSession object directly.
2019-08-07 15:32:30 -04:00
Antonio Ospite
80daea90f0 test: rtpbin_buffer_list: add a test for buffer lists on the recv path 2019-08-07 15:32:30 -04:00
Antonio Ospite
6f12f1cecc test: rtpbin_buffer_list: add test to verify that stats are correct
Add a test to verify that stats about sent and received packets are
correct even when using buffer lists.

NOTE: the newly introduced get_session_source_stats() selects the
desired source (sender or receiver) by filtering them by type (using the
get_sender parameter) rather than by ssrc because this simplifies the
code and it's good enough for testing purposes as there is usually one
source per type in the test setup.

Filtering by ssrc would have required handling asynchronous signals like
"on-new-sender-ssrc", with the relative locking, just to retrieve the
actual ssrc of the sender.
2019-04-02 13:02:28 +02:00
Antonio Ospite
a330012d6a test: rtpbin_buffer_list: move buffer list creation next to its validation
The tests create a buffer list and then use the chain_list callback to
verify that the correct packets have been pushed.

Move the creation and validation code next to each other so that the
reader can more easily understand what is going on.

While at it add some comments to introduce the two related functions.
2019-04-01 18:42:32 +00:00
Antonio Ospite
af8698e656 test: rtpbin_buffer_list: set the chain_list function directly in the test
The helper function set_chain_function does not really do anything useful, remove it.
2019-04-01 18:42:32 +00:00
Antonio Ospite
5567066bff test: rtpbin_buffer_list: make check_packet more flexible
Make it possible to differentiate between the position in the list and
the packet index in the global structures in check_packet, in some
future case the list may change, in case some element removes a buffer
from the list, and the two indices may not coincide.
2019-04-01 18:42:32 +00:00
Antonio Ospite
5807d79a9d test: rtpbin_buffer_list: factor out a function to create packets buffers 2019-04-01 18:42:32 +00:00
Antonio Ospite
6ab13c19b6 test: rtpbin_buffer_list: check if the chain_list function has been called
Make the test more useful to verify that the chain list function has
actually been called.
2019-04-01 18:42:32 +00:00
Antonio Ospite
623d3b930e test: rtpbin_buffer_list: port to GStreamer 1.0
Port the rtpbin_buffer_list test to GStreamer 1.0 and re-enable it.

Some other changes include:
  - the check on the caps has been moved from the buffer level to the
    pad level;
  - remove underscore prefix from static functions names, this is not
    idiomatic in C and rarely used in the other tests;
  - the unused header_buffer variable has been removed;
  - check_group() has been renamed to check_packet() because in
    GStreamer 1.0 there is no concept of "group" anymore, the comments
    have also been updated to reflect this.
2019-04-01 18:42:32 +00:00
Tim-Philipp Müller
230cf41cc9 Fix FSF address
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-04 00:07:18 +00:00
Wim Taymans
8e39d52bbb tests: make more tests compile 2012-01-03 14:16:28 +01:00
Benjamin Otte
3f511ec361 Add -Wwrite-strings to the configure flags
... and fix all warnings
2010-03-21 14:17:47 +01:00
Branko Subasic
779f67adc4 rtpbin: add support for buffer-list
Add support for sending buffer-lists.
Add unit test for testing that the buffer-list passed through rtpbin.

fixes #585839
2009-08-11 02:30:45 +01:00