Commit graph

234 commits

Author SHA1 Message Date
Tim-Philipp Müller
c5e1dc4ee6 tests: abi: fix abi test on 64-bit Windows
Add header with structure sizes for 64-bit windows as well.
They're almost the same as on Linux, but it looks like things
like padding unions get aligned slightly differently so there
are a handful of differences:

 sizeof(GstGhostPad) is 528, expected 536
 sizeof(GstPad) is 512, expected 520
 sizeof(GstPadProbeInfo) is 64, expected 72
 sizeof(GstProxyPad) is 520, expected 528
2018-01-11 12:04:31 +00:00
Tim-Philipp Müller
252ce5a093 Skip gst_deinit() if gstreamer was not initialized properly
Can happen if an error occurs during option parsing, for example.

https://bugzilla.gnome.org/show_bug.cgi?id=781914
2017-12-24 16:21:38 +01:00
Tim-Philipp Müller
cea9641fa9 aggregator: hook up to build system
https://bugzilla.gnome.org/show_bug.cgi?id=739010
2017-12-02 15:44:40 +00:00
Matthew Waters
86abf49c23 gst: add a promise object
An object that can be waited on and asked for asynchronous values.
In much the same way as promise/futures in js/java/etc

A callback can be installed for when the promise changes state.

Original idea by
Jan Schmidt <jan@centricular.com>

With contributions from
Nirbheek Chauhan <nirbheek@centricular.com>
Mathieu Duponchelle <mathieu@centricular.com>

https://bugzilla.gnome.org/show_bug.cgi?id=789843
2017-11-23 00:48:30 +11:00
Tim-Philipp Müller
6fdb4df0f8 tests: rewrite and enable dataurisrc test
Can't use playbin for core unit tests.

https://bugzilla.gnome.org/show_bug.cgi?id=774527
2016-11-28 11:19:15 +00:00
Tim-Philipp Müller
accde6ea16 tests: parse-launch: looks clean nowadays, so re-enable for valgrind
Also, the valgrind bits weren't hooked up properly anyway,
checking the wrong define.
2016-09-26 12:12:12 +01:00
Tim-Philipp Müller
e2cd6ffafc Remove old alloc tracing code now that we have a GstTracer-based replacement
It's been internal API only in 1.x.
2016-08-13 10:10:30 +01:00
Edward Hervey
63f6f05d66 gst: New Stream listing/selection system
* GstStream
* GstStreamCollection
* GST_EVENT_SELECT_STREAMS
* GST_MESSAGE_STREAM_COLLECTION
2016-06-30 12:31:06 +02:00
Julien Isorce
7d0abcc032 tests: add PTHREAD_CFLAGS for make check to pass on OS X
Currently "make check" fails with:
"error: argument unused during compilation: '-pthread'"

PTHREAD_CFLAGS now contains -Qunused-arguments to fix that.
Explanation here: http://savannah.gnu.org/patch/?8186#comment21

https://bugzilla.gnome.org/show_bug.cgi?id=747954
2016-04-11 18:03:49 +01:00
Tim-Philipp Müller
636aa20f28 tests: don't run tracerrecord in valgrind for now
Because of the way we implement logging and adding/removing
log functions currently (we leak a GList on purpose) this
test leaks.
2016-04-08 13:28:06 +01:00
Thiago Santos
682516402d tests: extend the AM_TESTS_ENVIRONMENT from check.mak
To get the CK_DEFAULT_TIMEOUT defined for all tests

https://bugzilla.gnome.org/show_bug.cgi?id=761472
2016-02-05 19:11:10 -03:00
Tim-Philipp Müller
8b88fc487f gst.h: Don't spew warnings if GST_USE_UNSTABLE_API is not defined
Only hide GstTracer and GstTracerRecord API behind GST_USE_UNSTABLE_API,
but don't spew any warnings, otherwise everyone has to define this
to avoid compiler warnings.

This reverts parts of commit 89ee5d948d.
2016-01-16 16:00:16 +00:00
Stefan Sauer
89ee5d948d tracer: add a GFlag for the tracer scope
Port all tracers. Add the GST_USE_UNSTABLE_API flag to the internal CFLAGS so
that we don't have to specify this for gir, docs, mkenum, ...
2016-01-16 13:31:51 +01:00
Stefan Sauer
10b78d872b tracerrecord: add a log record class
We use this class to register tracer log entry metadata and build a log
template. With the log template we can serialize log data very efficiently.
This also simplifies the logging code, since that is now a simple varargs
function that is not exposing the implementation details.

Add docs for the new class and basic tests.

Remove the previous log handler.

Fixes #760267
2016-01-15 21:54:01 +01:00
Havard Graff
28100e0b6a harness: add _set_forwarding function
To be able to disable the slightly "magic" forwarding of the
necessary events between the harnesses.

Also introduce a new test-suite for GstHarness, that documents the
feature, and should hopefully expand into documenting most of the
features the harness possesses.

https://bugzilla.gnome.org/show_bug.cgi?id=752746
2015-08-09 16:02:37 +01:00
Jan Schmidt
a198803bd6 basetransform: Split input buffer processing from output generation
Allow for sub-classes which want to collate incoming buffers or
split them into multiple output buffers by separating the input
buffer submission from output buffer generation and allowing
for looping of one of the phases depending on pull or push mode
operation.

https://bugzilla.gnome.org/show_bug.cgi?id=750033
2015-06-08 19:17:57 +10:00
Tim-Philipp Müller
cde5a6fea3 tests: define GST_CHECK_TEST_ENVIRONMENT_BEACON 2015-04-23 15:55:44 +01:00
Alex Ashley
abdafb0d64 protection: add GstProtectionMeta to support protected content
In order to support some types of protected streams (such as those
protected using DASH Common Encryption) some per-buffer information
needs to be passed between elements.

This commit adds a GstMeta type called GstProtectionMeta that allows
protection specific information to be added to a GstBuffer. An example
of its usage is qtdemux providing information to each output sample
that enables a downstream element to decrypt it.

This commit adds a utility function to select a supported protection
system from the installed Decryption elements found in the registry.
The gst_protection_select_system function that takes an array of
identifiers and searches the registry for a element of klass Decryptor that
supports one or more of the supplied identifiers. If multiple elements
are found, the one with the highest rank is selected.

This commit adds a unit test for the gst_protection_select_system
function that adds a fake Decryptor element to the registry and then
checks that it can correctly be selected by the utility function.

This commit adds a unit test for GstProtectionMeta that creates
GstProtectionMeta and adds & removes it from a buffer and performs some
simple reference count checks.

API: gst_buffer_add_protection_meta()
API: gst_buffer_get_protection_meta()
API: gst_protection_select_system()
API: gst_protection_meta_api_get_type()
API: gst_protection_meta_get_info()

https://bugzilla.gnome.org/show_bug.cgi?id=705991
2015-04-18 12:24:06 +01:00
Edward Hervey
0865bc02ea tests: Use AM_TESTS_ENVIRONMENT
Needed by the new automake test runner
2015-04-08 16:08:24 +02:00
HoonHee Lee
fadabe8b78 streamiddemux: Add streamiddemux element
Demultiplex a stream to multiple source pads based on the stream ids from the
stream-start events. This basically reverses the behaviour of funnel.

https://bugzilla.gnome.org/show_bug.cgi?id=707605
2015-03-12 14:42:18 +00:00
Tim-Philipp Müller
0c3f1850be tests: add some basic unit tests for our printf stuff
To test new %I32 support.

https://bugzilla.gnome.org/show_bug.cgi?id=744281
2015-03-12 13:29:05 +00:00
Sebastian Dröge
96f0544cbd concat: Add unit tests for concat element 2014-08-12 15:39:09 +03:00
Thiago Santos
0d5ddc96f2 Revert "tests: taglist: add basic test for taglists serialization"
This reverts commit 85d23d19b7.

There was already a gsttag.c tests file, this test has been merged
in it in the previous commit
2014-07-21 12:44:40 -03:00
Thiago Santos
85d23d19b7 tests: taglist: add basic test for taglists serialization
Make sure it works with empty taglists
2014-07-21 11:42:05 -03:00
Olivier Crête
fc87c5df5e device: Add unit tests 2014-06-26 21:01:38 -04:00
Thiago Santos
9e8bd15c12 flowcombiner: add GstFlowCombiner
Adds a utility struct that is capable of storing and aggregating flow returns
associated with pads.

This way all demuxers will have a standard function to use and have the
same expected results.

Includes tests.

https://bugzilla.gnome.org/show_bug.cgi?id=709224
2014-05-26 15:29:53 -03:00
Wim Taymans
45855e2795 Add new downloadbuffer element
See https://bugzilla.gnome.org/show_bug.cgi?id=680183
2014-05-08 15:53:45 +02:00
Stefan Sauer
f9a5a24211 bufferpool: add a new testsuite or the pool
Start with some basic tests.
2014-01-30 12:43:45 +01:00
Thiago Santos
aad8123ff9 tests: baseparse: add basic test for baseparse
Just a small test to check that basic playback works
2014-01-13 08:43:28 -03:00
Tim-Philipp Müller
430df345c4 tests: add unit test for bitreader, bytereader and bytewriter with no inlining used 2013-12-14 21:20:45 +00:00
Sebastian Dröge
f5f0dd50c8 context: Add unit test for GstContext 2013-04-17 12:44:29 +02:00
Sebastian Dröge
7477b25df5 caps: Add new data type for handling caps features to the caps
These are meant to specify features in caps that are required
for a specific structure, for example a specific memory type
or meta.

Semantically they could be though of as an extension of the media
type name of the structures and are handled exactly like that.
2013-03-31 18:15:52 +02:00
Tim-Philipp Müller
64eee27ebc Use GST_*_1_0 environment variables everywhere
The _1_0 suffixed environment variables override the
non-suffixed ones, so if we're in an environment that
sets the _1_0 suffixed ones, such as jhbuild, we need
to set those to make sure ours actually always get
used.
2013-01-15 13:47:32 +00:00
Sebastian Rasmussen
e58da2a22d check: add GstTestClock as a deterministic clock for testing
API: GstTestClock
API: gst_test_clock_new()
API: gst_test_clock_new_with_start_time()
API: gst_test_clock_set_time()
API: gst_test_clock_advance_time()

https://bugzilla.gnome.org/show_bug.cgi?id=683012
2012-11-13 21:19:57 +00:00
Wim Taymans
c6e754635c tests: enable library abi checks 2012-09-27 10:37:32 +02:00
Wim Taymans
58443d6f2b tests: add abi checks
Enable abi checks again.
Fix abi sizes for x86_64, copy the file to other archs.
2012-09-26 17:11:05 +02:00
Tim-Philipp Müller
4ab9587417 tests: add check for gst-inspect --exists functionality 2012-09-01 23:02:10 +01:00
Tim-Philipp Müller
1507ce3907 tests: fix collectpads test
After an EOS we must send a FLUSH_STOP event if
we want to send data again.
2012-08-12 18:36:09 +01:00
Tim-Philipp Müller
31e28180b3 tests: fix pipeline unit test
Which was disabled because it failed.
2012-08-12 16:37:02 +01:00
Edward Hervey
041787ac82 check: New unit test for GstQueueArray 2012-07-04 17:46:54 +02:00
Mark Nauwelaerts
e076e36840 collectpads2: rename to collectpads 2012-04-17 15:07:54 +02:00
Sebastian Dröge
b0d89da6b6 gst: Change versioning
Remove GST_MAJORMINOR and replace it by GST_API_VERSION
Also set GST_VERSION_{MAJOR,MINOR,MICRO,NANO} explicitely
now.

All versions are at 1.0.0 now for the release soon but
API/ABI can still change until the 1.0.0 release.

Next release versions until 1.0.0 will be 0.10.9X and
these will be release candidates. GST_VERSION_* will
nonetheless stay at 1.0.0.0.
2012-04-04 14:28:55 +02:00
Stefan Sauer
1074a4e99a Merge branch '0.10'
Conflicts:
	docs/gst/gstreamer-sections.txt
	gst/Makefile.am
	gst/gst.c
	gst/gst.h
	gst/gstevent.c
	gst/gstevent.h
	gst/gstmessage.h
	gst/gstquark.c
	gst/gstquark.h
	gst/gstquery.c
	gst/gstquery.h
	tests/check/Makefile.am
2012-04-02 21:33:10 +02:00
Alexander Saprykin
9b80982c53 gstchecks: Add unit test for the GstTocSetter 2012-04-02 10:49:38 +02:00
Alexander Saprykin
7fd9bb5cd2 gstchecks: Add unit test for the GstToc 2012-04-02 10:49:38 +02:00
Tim-Philipp Müller
e09fe53a22 Merge remote-tracking branch 'origin/master' into 0.11
Conflicts:
	common
	gst/gstpad.h
	gst/gsttask.c
	libs/gst/base/gstcollectpads2.h
2012-03-08 19:55:30 +00:00
Tim-Philipp Müller
799d69b038 tests: add minimal basesrc ! sink seeking unit test
Should reproduce 'GStreamer-WARNING **: wrong STREAM_LOCK count 0'
warnings (with make pipelines/seek.torture or pipelines/seek.forever
anyway, since it appears to be racy).

https://bugzilla.gnome.org/show_bug.cgi?id=670846
2012-03-08 16:19:55 +00:00
David Schleef
0f0f355bfa Fix gap in Makefile 2012-02-23 08:49:19 -08:00
Sebastian Dröge
b9e199798e collectpads2: Unit test is valgrind clean now 2012-01-26 11:42:29 +01:00
Sebastian Dröge
0ff349fb38 collectpads2: Port collectpads unit test to collectpads2
Currently fails but really shouldn't.
2012-01-26 11:39:22 +01:00