diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/SwizzlerTest.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/SwizzlerTest.cpp b/tests/SwizzlerTest.cpp index e1626d52f1..1b34669f97 100644 --- a/tests/SwizzlerTest.cpp +++ b/tests/SwizzlerTest.cpp @@ -5,6 +5,7 @@ * found in the LICENSE file. */ +#include "SkSwizzle.h" #include "SkSwizzler.h" #include "Test.h" #include "SkOpts.h" @@ -157,3 +158,12 @@ DEF_TEST(SwizzleOpts, r) { SkOpts::RGBA_to_bgrA(&dst, &src, 1); REPORTER_ASSERT(r, dst == 0xFA04ADCA); } + +DEF_TEST(PublicSwizzleOpts, r) { + uint32_t dst, src; + + // check a totally arbitrary color + src = 0xFACEB004; + SkSwapRB(&dst, &src, 1); + REPORTER_ASSERT(r, dst == 0xFA04B0CE); +} |