Skip to content

Commit

Permalink
Also test encoding 8kHz data.
Browse files Browse the repository at this point in the history
  • Loading branch information
sobomax committed Jul 29, 2016
1 parent 009bc9d commit 808f20e
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
10 changes: 6 additions & 4 deletions Makefile
Expand Up @@ -12,18 +12,20 @@ INCS= g722.h g722_private.h g722_encoder.h g722_decoder.h
WARNS?= 2
CFLAGS+= -I${.CURDIR} ${PICFLAG}

TEST_OUT_FILE= test.raw test.raw.16k pcminb.g722 pcminb.raw.16k
TEST_OUT_FILES= test.raw test.raw.16k pcminb.g722 pcminb.raw.16k \
test.g722.out

CLEANFILES+=test test.raw test.raw.16k pcminb.g722 pcminb.raw.16k
CLEANFILES+=test ${TEST_OUT_FILES}

test: test.c lib${LIB}.a test.g722 pcminb.dat Makefile
rm -f ${TEST_OUT_FILE}
rm -f ${TEST_OUT_FILES}
${CC} ${CFLAGS} -o ${.TARGET} test.c lib${LIB}.a -lm
${.CURDIR}/${.TARGET} test.g722 test.raw
${.CURDIR}/${.TARGET} --sln16k test.g722 test.raw.16k
${.CURDIR}/${.TARGET} --enc --sln16k --bend pcminb.dat pcminb.g722
${.CURDIR}/${.TARGET} --sln16k --bend pcminb.g722 pcminb.raw.16k
sha256 test.raw test.raw.16k pcminb.g722 pcminb.raw.16k | \
${.CURDIR}/${.TARGET} --enc test.raw test.g722.out
sha256 ${TEST_OUT_FILES} | \
diff test.checksum -

.include <bsd.lib.mk>
1 change: 1 addition & 0 deletions test.checksum
Expand Up @@ -2,3 +2,4 @@ SHA256 (test.raw) = 8eb29e8e9feb9709d96c7bbda37cbb2f77510fcfab2d1f48a495178cd223
SHA256 (test.raw.16k) = a886f22d37ecd356e1963072bc481ed2c5dd12539428188d9779d33a520f3ff8
SHA256 (pcminb.g722) = 15570a43acb0ff0f30aced265973eeb7733023be3697cdff0df36c41e88385c6
SHA256 (pcminb.raw.16k) = 1d3f23110538d25b96631db4aff3eff84f99b0859140302a99b323b259b24b89
SHA256 (test.g722.out) = cb8edfaa7b5a85384dde8e0c9976f5247294732d6caf32c07b94510fc8844403

0 comments on commit 808f20e

Please sign in to comment.