mirror of
https://github.com/google/brotli.git
synced 2024-11-21 19:20:09 +00:00
reword cmake test generator warning
PiperOrigin-RevId: 564371898
This commit is contained in:
parent
e8569f79fc
commit
cf95fbb9c5
@ -261,7 +261,7 @@ if(NOT BROTLI_DISABLE_TESTS)
|
||||
-P ${CMAKE_CURRENT_SOURCE_DIR}/tests/run-roundtrip-test.cmake)
|
||||
endforeach()
|
||||
else()
|
||||
message(WARNING "Test file ${INPUT} does not exist.")
|
||||
message(NOTICE "Test file ${INPUT} does not exist; OK on tarball builds")
|
||||
endif()
|
||||
endforeach()
|
||||
|
||||
|
@ -1,17 +0,0 @@
|
||||
#brotli/tests
|
||||
|
||||
BROTLI = ..
|
||||
|
||||
all: test
|
||||
|
||||
test: deps
|
||||
./compatibility_test.sh
|
||||
./roundtrip_test.sh
|
||||
|
||||
deps :
|
||||
$(MAKE) -C $(BROTLI) brotli
|
||||
|
||||
clean :
|
||||
rm -f testdata/*.{br,unbr,uncompressed}
|
||||
rm -f $(BROTLI)/{enc,dec,tools}/*.{un,}br
|
||||
$(MAKE) -C $(BROTLI)/tools clean
|
@ -1,25 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Test that the brotli command-line tool can decompress old brotli-compressed
|
||||
# files.
|
||||
#
|
||||
# The first argument may be a wrapper for brotli, such as 'qemu-arm'.
|
||||
|
||||
set -o errexit
|
||||
|
||||
BROTLI_WRAPPER=$1
|
||||
BROTLI="${BROTLI_WRAPPER} bin/brotli"
|
||||
TMP_DIR=bin/tmp
|
||||
|
||||
for file in tests/testdata/*.compressed*; do
|
||||
echo "Testing decompression of file $file"
|
||||
expected=${file%.compressed*}
|
||||
uncompressed=${TMP_DIR}/${expected##*/}.uncompressed
|
||||
echo $uncompressed
|
||||
$BROTLI $file -fdo $uncompressed
|
||||
diff -q $uncompressed $expected
|
||||
# Test the streaming version
|
||||
cat $file | $BROTLI -dc > $uncompressed
|
||||
diff -q $uncompressed $expected
|
||||
rm -f $uncompressed
|
||||
done
|
@ -1,36 +0,0 @@
|
||||
#!/usr/bin/env bash
|
||||
#
|
||||
# Roundtrip test for the brotli command-line tool.
|
||||
#
|
||||
# The first argument may be a wrapper for brotli, such as 'qemu-arm'.
|
||||
|
||||
set -o errexit
|
||||
|
||||
BROTLI_WRAPPER=$1
|
||||
BROTLI="${BROTLI_WRAPPER} bin/brotli"
|
||||
TMP_DIR=bin/tmp
|
||||
INPUTS="""
|
||||
tests/testdata/alice29.txt
|
||||
tests/testdata/asyoulik.txt
|
||||
tests/testdata/lcet10.txt
|
||||
tests/testdata/plrabn12.txt
|
||||
c/enc/encode.c
|
||||
c/common/dictionary.h
|
||||
c/dec/decode.c
|
||||
"""
|
||||
|
||||
for file in $INPUTS; do
|
||||
if [ -f $file ]; then
|
||||
for quality in 1 6 9 11; do
|
||||
echo "Roundtrip testing $file at quality $quality"
|
||||
compressed=${TMP_DIR}/${file##*/}.br
|
||||
uncompressed=${TMP_DIR}/${file##*/}.unbr
|
||||
$BROTLI -fq $quality $file -o $compressed
|
||||
$BROTLI $compressed -fdo $uncompressed
|
||||
diff -q $file $uncompressed
|
||||
# Test the streaming version
|
||||
cat $file | $BROTLI -cq $quality | $BROTLI -cd >$uncompressed
|
||||
diff -q $file $uncompressed
|
||||
done
|
||||
fi
|
||||
done
|
Loading…
Reference in New Issue
Block a user