[FFmpeg-devel] [PATCH] libavutil/encryption_info: Add unit tests.

Jacob Trimble modmaker at google.com
Tue Jun 26 19:28:01 EEST 2018


On Mon, Jun 25, 2018 at 5:30 PM Michael Niedermayer
<michael at niedermayer.cc> wrote:
>
> On Fri, Jun 01, 2018 at 12:51:48PM -0700, Jacob Trimble wrote:
> > Signed-off-by: Jacob Trimble <modmaker at google.com>
> > ---
> >  libavutil/Makefile                |   1 +
> >  libavutil/encryption_info.h       |   2 +-
> >  libavutil/tests/.gitignore        |   2 +
> >  libavutil/tests/encryption_info.c | 176 ++++++++++++++++++++++++++++++
> >  tests/fate/libavutil.mak          |   4 +
> >  tests/ref/fate/encryption-info    |   0
> >  6 files changed, 184 insertions(+), 1 deletion(-)
> >  create mode 100644 libavutil/tests/encryption_info.c
> >  create mode 100644 tests/ref/fate/encryption-info
> >
> > diff --git a/libavutil/Makefile b/libavutil/Makefile
> > index d0632f16a6..9ed24cfc82 100644
> > --- a/libavutil/Makefile
> > +++ b/libavutil/Makefile
> > @@ -200,6 +200,7 @@ TESTPROGS = adler32                                                     \
> >              des                                                         \
> >              dict                                                        \
> >              display                                                     \
> > +            encryption_info                                             \
> >              error                                                       \
> >              eval                                                        \
> >              file                                                        \
>
> > diff --git a/libavutil/encryption_info.h b/libavutil/encryption_info.h
> > index 9140968fde..8fe7ebfe43 100644
> > --- a/libavutil/encryption_info.h
> > +++ b/libavutil/encryption_info.h
> > @@ -129,7 +129,7 @@ typedef struct AVEncryptionInitInfo {
> >   *
> >   * @param subsample_count The number of subsamples.
> >   * @param key_id_size The number of bytes in the key ID, should be 16.
> > - * @param key_id_size The number of bytes in the IV, should be 16.
> > + * @param iv_size The number of bytes in the IV, should be 16.
> >   *
> >   * @return The new AVEncryptionInfo structure, or NULL on error.
> >   */
>
> How is this related to adding a test ?
>

I guess it's unrelated, created a separate patch for it.

>
>
> > diff --git a/libavutil/tests/.gitignore b/libavutil/tests/.gitignore
> > index 71f75a8ee9..9d90827954 100644
> > --- a/libavutil/tests/.gitignore
> > +++ b/libavutil/tests/.gitignore
> > @@ -17,6 +17,7 @@
> >  /dict
> >  /display
> >  /error
> > +/encryption_info
> >  /eval
> >  /fifo
> >  /file
>
> > @@ -24,6 +25,7 @@
> >  /hmac
> >  /hwdevice
> >  /imgutils
> > +/integer
> >  /lfg
> >  /lls
> >  /log
>
> this also looks unrelated

Same.

>
>
> [...]
> --
> Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
>
> Opposition brings concord. Out of discord comes the fairest harmony.
> -- Heraclitus
> _______________________________________________
> ffmpeg-devel mailing list
> ffmpeg-devel at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-devel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-libavutil-encryption_info-Add-unit-tests-v2.patch
Type: text/x-patch
Size: 9080 bytes
Desc: not available
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20180626/1e8e9a52/attachment.bin>


More information about the ffmpeg-devel mailing list