#!/bin/sh

set -e

# The resulting file of dwebp differs from examples/test_ref.ppm, so we need to
# compare it against that from the current (0.5.2-1+deb9u2) version in stretch.

dwebp examples/test.webp -ppm -o test.ppm
diff debian/tests/test-stretch-0.5.2-1+deb9u2.ppm test.ppm

dwebp examples/test.webp -tiff -o test.tiff
cwebp test.tiff -lossless -o test-from-tiff.webp
dwebp test-from-tiff.webp -ppm -o test2.ppm
diff debian/tests/test-stretch-0.5.2-1+deb9u2.ppm test2.ppm
