Add basic tests for the lz4 integration
This commit is contained in:
parent
360238733a
commit
5705d9f25a
@ -22,6 +22,8 @@ matrix:
|
|||||||
- env: Cmd='make ppcinstall && make ppcfuzz'
|
- env: Cmd='make ppcinstall && make ppcfuzz'
|
||||||
- env: Cmd='make ppcinstall && make ppc64fuzz'
|
- env: Cmd='make ppcinstall && make ppc64fuzz'
|
||||||
|
|
||||||
|
- env: Cmd='make lz4install && make -C tests test-lz4'
|
||||||
|
|
||||||
git:
|
git:
|
||||||
depth: 1
|
depth: 1
|
||||||
|
|
||||||
|
5
Makefile
5
Makefile
@ -97,6 +97,7 @@ clean:
|
|||||||
@$(MAKE) -C examples/ $@ > $(VOID)
|
@$(MAKE) -C examples/ $@ > $(VOID)
|
||||||
@$(MAKE) -C contrib/gen_html $@ > $(VOID)
|
@$(MAKE) -C contrib/gen_html $@ > $(VOID)
|
||||||
@$(RM) zstd$(EXT) zstdmt$(EXT) tmp*
|
@$(RM) zstd$(EXT) zstdmt$(EXT) tmp*
|
||||||
|
@$(RM) -r lz4
|
||||||
@echo Cleaning completed
|
@echo Cleaning completed
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
#------------------------------------------------------------------------------
|
||||||
@ -274,6 +275,10 @@ gpp6install: apt-add-repo
|
|||||||
clang38install:
|
clang38install:
|
||||||
APT_PACKAGES="clang-3.8" $(MAKE) apt-install
|
APT_PACKAGES="clang-3.8" $(MAKE) apt-install
|
||||||
|
|
||||||
|
# Ubuntu 14.04 ships a too-old lz4
|
||||||
|
lz4install:
|
||||||
|
[ -e lz4 ] || git clone https://github.com/lz4/lz4 && sudo $(MAKE) -C lz4 install
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -374,4 +374,26 @@ test-decodecorpus-cli: decodecorpus
|
|||||||
test-pool: poolTests
|
test-pool: poolTests
|
||||||
$(QEMU_SYS) ./poolTests
|
$(QEMU_SYS) ./poolTests
|
||||||
|
|
||||||
|
test-lz4: ZSTD = LD_LIBRARY_PATH=/usr/local/lib $(PRGDIR)/zstd
|
||||||
|
test-lz4: zstd decodecorpus
|
||||||
|
./decodecorpus -ptmp
|
||||||
|
# lz4 -> zstd
|
||||||
|
lz4 < tmp | \
|
||||||
|
$(ZSTD) -d | \
|
||||||
|
cmp - tmp
|
||||||
|
# zstd -> lz4
|
||||||
|
$(ZSTD) --format=lz4 < tmp | \
|
||||||
|
lz4 -d | \
|
||||||
|
cmp - tmp
|
||||||
|
# zstd -> zstd
|
||||||
|
$(ZSTD) --format=lz4 < tmp | \
|
||||||
|
$(ZSTD) -d | \
|
||||||
|
cmp - tmp
|
||||||
|
# zstd -> zstd
|
||||||
|
$(ZSTD) < tmp | \
|
||||||
|
$(ZSTD) -d | \
|
||||||
|
cmp - tmp
|
||||||
|
|
||||||
|
rm tmp
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
Loading…
Reference in New Issue
Block a user