[FFmpeg-devel] [PATCH] libavcodec/tests: Added test for libavcodec/avpacket.c

Michael Niedermayer michael at niedermayer.cc
Wed Oct 26 15:56:01 EEST 2016


On Wed, Oct 26, 2016 at 02:00:46PM +0200, wm4 wrote:
> On Sat, 22 Oct 2016 23:40:42 -0700
> Thomas Turner <thomastdt at googlemail.com> wrote:
> 
> > Function(s) Tested: av_packet_clone().
> > 
> > This test checks if av_packet_clone() can successfully make a copy of an AVPacket.
> > Compares all data members in AVPacket EXCEPT for "buf" because "buf" is initialized
> > to NIL in the original AVPacket [to be cloned].
> > 
> > This test also prints out the all the contents of the original and cloned AVPackets.
> > 
> > Signed-off-by: Thomas Turner <thomastdt at googlemail.com>
> > ---
> 
> Am I the only one who thinks this test is overly complex and worthless?
> (Checks if each field got copied... come on, that's not useful. And
> would probably bitrot quickly as nobody would add new fields to the
> test anyway.)

what do you suggest, how to test it ?
or should we deprecate av_packet_clone()
nothing uses it, so the total lack of tests and uses means noone
would notice (quickly) if it broke ever

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Dictatorship naturally arises out of democracy, and the most aggravated
form of tyranny and slavery out of the most extreme liberty. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20161026/420f1b13/attachment.sig>


More information about the ffmpeg-devel mailing list