mesa/formats: make format testing a gtest
authorNanley Chery <nanley.g.chery@intel.com>
Tue, 18 Aug 2015 19:42:57 +0000 (12:42 -0700)
committerNanley Chery <nanley.g.chery@intel.com>
Tue, 25 Aug 2015 22:45:13 +0000 (15:45 -0700)
commit8e581747d2342950ff44488064eef53768b3ae82
treedab342b9dde865a36b6e09e724dec95f0ca62283
parent1bec29d04d970b4d60a8c60252313f25bebfe024
mesa/formats: make format testing a gtest

We currently check that our format info table is sane during context
initialization in debug builds. Perform this check during
`make check` instead. This enables format testing in release builds
and removes the requirement of an exhuastive switch for
_mesa_uncompressed_format_to_type_and_comps().

v2. indentation and conditional inclusion fixes (Chad).
    allow tests to continue running if any format fails
    and display the failing format name.

Reviewed-by: Chad Versace <chad.versace@intel.com>
Signed-off-by: Nanley Chery <nanley.g.chery@intel.com>
src/mesa/main/context.c
src/mesa/main/formats.c
src/mesa/main/tests/Makefile.am
src/mesa/main/tests/mesa_formats.cpp [new file with mode: 0644]