Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/GStreamer/gst-plugins-good.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>2012-02-28 02:45:54 +0400
committerMark Nauwelaerts <mark.nauwelaerts@collabora.co.uk>2012-02-28 02:45:54 +0400
commitb863df570f0fc6f1e868b40c7d97f19c003e93a5 (patch)
tree0ea132bdd988e5c2593a882a5fdf924cbac2304f /tests/check/elements/wavpackenc.c
parent9beda57c3a81eb920324654fdb50f5610720f999 (diff)
wavpackenc: port to audioencoder
Also adjust unit test to slightly modified behaviour.
Diffstat (limited to 'tests/check/elements/wavpackenc.c')
-rw-r--r--tests/check/elements/wavpackenc.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/tests/check/elements/wavpackenc.c b/tests/check/elements/wavpackenc.c
index 153668a9d..af852aaa2 100644
--- a/tests/check/elements/wavpackenc.c
+++ b/tests/check/elements/wavpackenc.c
@@ -32,14 +32,14 @@ static GstBus *bus;
#define RAW_CAPS_STRING "audio/x-raw-int, " \
"width = (int) 32, " \
- "depth = (int) 16, " \
+ "depth = (int) 32, " \
"channels = (int) 1, " \
"rate = (int) 44100, " \
"endianness = (int) BYTE_ORDER, " \
"signed = (boolean) true"
#define WAVPACK_CAPS_STRING "audio/x-wavpack, " \
- "width = (int) 16, " \
+ "width = (int) 32, " \
"channels = (int) 1, " \
"rate = (int) 44100, " \
"framed = (boolean) true"
@@ -48,7 +48,7 @@ static GstStaticPadTemplate sinktemplate = GST_STATIC_PAD_TEMPLATE ("sink",
GST_PAD_SINK,
GST_PAD_ALWAYS,
GST_STATIC_CAPS ("audio/x-wavpack, "
- "width = (int) 16, "
+ "width = (int) 32, "
"channels = (int) 1, "
"rate = (int) 44100, " "framed = (boolean) true"));
@@ -57,7 +57,7 @@ static GstStaticPadTemplate srctemplate = GST_STATIC_PAD_TEMPLATE ("src",
GST_PAD_ALWAYS,
GST_STATIC_CAPS ("audio/x-raw-int, "
"width = (int) 32, "
- "depth = (int) 16, "
+ "depth = (int) 32, "
"channels = (int) 1, "
"rate = (int) 44100, "
"endianness = (int) BYTE_ORDER, " "signed = (boolean) true"));
@@ -118,13 +118,10 @@ GST_START_TEST (test_encode_silence)
gst_caps_unref (caps);
GST_BUFFER_TIMESTAMP (inbuffer) = 0;
ASSERT_BUFFER_REFCOUNT (inbuffer, "inbuffer", 1);
- gst_buffer_ref (inbuffer);
gst_element_set_bus (wavpackenc, bus);
fail_unless_equals_int (gst_pad_push (mysrcpad, inbuffer), GST_FLOW_OK);
- ASSERT_BUFFER_REFCOUNT (inbuffer, "inbuffer", 1);
- gst_buffer_unref (inbuffer);
fail_if (gst_pad_push_event (mysrcpad, eos) != TRUE);
@@ -134,9 +131,7 @@ GST_START_TEST (test_encode_silence)
fail_if (outbuffer == NULL);
fail_unless_equals_int (GST_BUFFER_TIMESTAMP (outbuffer), 0);
- fail_unless_equals_int (GST_BUFFER_OFFSET (outbuffer), 0);
fail_unless_equals_int (GST_BUFFER_DURATION (outbuffer), 5668934);
- fail_unless_equals_int (GST_BUFFER_OFFSET_END (outbuffer), 250);
fail_unless (memcmp (GST_BUFFER_DATA (outbuffer), "wvpk", 4) == 0,
"Failed to encode to valid Wavpack frames");