[Libva] [PATCH intel-driver 01/11] test: move ASSERT_NO_FAILURE macro to test.h
Sean V Kelley
seanvk at posteo.de
Mon Oct 3 18:46:00 UTC 2016
On Thu, 2016-09-29 at 15:19 +0000, Eoff, Ullysses A wrote:
> Yes, my apologies… I will be sure to add a cover from now on.
>
> FWIW…
>
> This patch series moves several of the auxiliary data input
> routines/classes for encode into the jpeg test data files in order to
> clean up the actual test implementation file. Also move some of the
> common/generic test macros and functions to appropriate files. The
> JPEG::Encode::TestInput class was refactored to only allow it to be
> created with a shared_ptr. In addition, there is a typedef fix (not
> critical) and YUV format conversion was moved to the class. YUV
> input initialization and conversion functions were also optimized a
> bit to avoid excessive intermediate copies. Finally, added support
> to cover YUY2, UYVY, and Y800 input formats in the JPEG encode tests.
>
> Note that the Y800 test cases expose a decode bug in the driver for
> gen8+ and causes the test program to abort. The “jpeg/dec: gen8+ set
> correct fourcc for monochrome decode” driver patch will fix this and
> is on the ML.
lgtm, applied.
Thanks,
Sean
>
> Thanks,
> U. Artie
>
> From: Sean V Kelley [mailto:seanvk at posteo.de]
> Sent: Wednesday, September 28, 2016 1:48 PM
> To: Eoff, Ullysses A <ullysses.a.eoff at intel.com>; libva at lists.freedes
> ktop.org
> Subject: Re: [Libva] [PATCH intel-driver 01/11] test: move
> ASSERT_NO_FAILURE macro to test.h
>
>
> On Wed, 2016-09-28 at 13:36 -0700, U. Artie Eoff wrote:
> Both jpeg decode and encode test files use this macro.
> So move it to the common test.h header to avoid duplicating
> it.
>
> Please add brief cover in the future (patch 00/N) when you have a
> large series, even if they are mostly refactoring. I would like to
> see a concise summary for a large number of changes.
>
> Thanks,
>
> Sean
>
>
> Signed-off-by: U. Artie Eoff <ullysses.a.eoff at intel.com>
> ---
> test/i965_jpeg_decode_test.cpp | 4 ----
> test/i965_jpeg_encode_test.cpp | 4 ----
> test/test.h | 4 ++++
> 3 files changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/test/i965_jpeg_decode_test.cpp
> b/test/i965_jpeg_decode_test.cpp
> index b022c2e67c3e..6b8462564cfd 100644
> --- a/test/i965_jpeg_decode_test.cpp
> +++ b/test/i965_jpeg_decode_test.cpp
> @@ -194,10 +194,6 @@ protected:
> PictureData::SharedConst pd;
> };
>
> -#define ASSERT_NO_FAILURE(statement) \
> - statement; \
> - ASSERT_FALSE(HasFailure());
> -
> TEST_P(FourCCTest, Decode)
> {
> struct i965_driver_data *i965(*this);
> diff --git a/test/i965_jpeg_encode_test.cpp
> b/test/i965_jpeg_encode_test.cpp
> index 08d80c4f75b7..80ca1fdc62be 100644
> --- a/test/i965_jpeg_encode_test.cpp
> +++ b/test/i965_jpeg_encode_test.cpp
> @@ -157,10 +157,6 @@ const TestInput::Shared NV12toI420(const
> TestInput::SharedConst& nv12)
> return i420;
> }
>
> -#define ASSERT_NO_FAILURE(statement) \
> - statement; \
> - ASSERT_FALSE(HasFailure());
> -
> class JPEGEncodeInputTest
> : public JPEGEncodeTest
> , public ::testing::WithParamInterface<
> diff --git a/test/test.h b/test/test.h
> index afca9a5ed2d6..000284a2ca2e 100644
> --- a/test/test.h
> +++ b/test/test.h
> @@ -66,6 +66,10 @@
> #define ASSERT_PTR_NULL(ptr) \
> ASSERT_TRUE(NULL == (ptr))
>
> +#define ASSERT_NO_FAILURE(statement) \
> + statement; \
> + ASSERT_FALSE(HasFailure());
> +
> class VaapiStatus
> {
> public:
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 801 bytes
Desc: This is a digitally signed message part
URL: <https://lists.freedesktop.org/archives/libva/attachments/20161003/9f64bced/attachment.sig>
More information about the Libva
mailing list