Commit Graph

537 Commits

Author SHA1 Message Date
Erik de Castro Lopo
b25f7f3bb3 Revert "src/sndfile.c : Make WAV/GSM610 with sample rates other than 8kHz invalid."
Commit was a0be1713b5.

Also revert the related commits:
* e4253e1609
* 77504d6abd
2014-07-03 21:30:52 +10:00
Erik de Castro Lopo
e4253e1609 tests/ : Fix tests for SF_FORMAT_GSM610.
Commit a0be1713 only allows SF_FORMAT_GSM610 to be used with a sample
rate of 8Khz. Adjust tests to use sample rate of 8000 whenever the
sub-format isf GSM610.
2014-07-02 19:43:37 +10:00
Erik de Castro Lopo
852d6e612a tests/(floating_point|scale_clip)_test.def : Quote hex literals.
Versions of autogen before 5.18.1 accepted bare hexadecimal literals
but later versions need those hex literals quoted. See:

    https://sourceforge.net/p/autogen/bugs/162/
2014-06-30 18:32:14 +10:00
Erik de Castro Lopo
9b09b70042 tests/write_read_test.tpl : Rename 'long_file_okz' -> 'long_file_ok'. 2014-06-28 23:11:13 +10:00
Erik de Castro Lopo
080dcdafa5 tests/floating_point_test.tpl : Adjust test targets for -fsanitizer=integer. 2014-04-05 13:35:04 +11:00
Erik de Castro Lopo
3e91aaf7aa src/* tests/* : Fix problems found by clang sanitizer. 2014-04-05 13:34:35 +11:00
Erik de Castro Lopo
21c3175420 src/command.c : Fix calculations of siganl max with odd channel numbers.
Also add a test for this.

Closes: https://github.com/erikd/libsndfile/issues/58
2014-03-01 20:28:50 +11:00
Andy Aylward
43c3df56e6 tests/cpp_test.cc : Fix text in error message.
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2014-01-04 07:29:29 +11:00
Vadim Markovtsev
b53a11e75b Added support for building in a separate directory
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2013-12-20 20:52:50 +11:00
Erik de Castro Lopo
040d7fd5c8 tests/floating_point_test.tpl : Remove old HAVE_LRINT_REPLACEMENT usage. 2013-07-31 18:32:14 +10:00
Erik de Castro Lopo
93bdeabf07 Fix a couple of warnings uncovered by the clang compiler. 2013-07-13 18:07:42 +10:00
Erik de Castro Lopo
471281a7a3 tests/floating_point_test.tpl : Reduce tolerance of a couple of tests.
A couple of tests were failing when compiled with gcc-4.8 (and
gcc-snapshot/4.9.0 from Debian). The tests changed were for 32 bit
ALAC (test result changed from -186 to -181 dB signal-to-noise) and
for doubles (test results changed from -300 to -205 dB signal-to-noise).
2013-07-12 19:10:13 +10:00
Erik de Castro Lopo
96bfd88297 Add *.exe CLEANFILES in Makefile.am. 2013-06-23 21:33:37 +10:00
Erik de Castro Lopo
71a06e52d4 Add a couple of 'seek to end of file' tests. 2013-06-23 11:18:26 +10:00
Karl Lindén
958263fbd7 Do not use old variable INCLUDES and use modern AM_INIT_AUTOMAKE invocation.
Signed-off-by: Erik de Castro Lopo <erikd@mega-nerd.com>
2013-04-07 20:05:08 +10:00
Erik de Castro Lopo
ea31ce4588 tests/dft_cmp.c : Fix buffer overflow detected using gcc-4.8.
This was a buffer overflow in libsndfile's test suite code, not
in the actual library code.
2013-03-28 18:11:14 +11:00
Erik de Castro Lopo
95714e91b3 tests/test_wrapper.sh.in : Add cart tests to command_test. 2013-02-11 19:57:49 +11:00
Erik de Castro Lopo
1640ab2eef tests/command_test.c : Use cart_test on RF64 files as well. 2013-02-11 19:57:49 +11:00
Erik de Castro Lopo
1fa256cd7a sndfile.h.in : Replace type 'long' with type 'int32_t' in SF_CART_INFO.
Type 'long' can be either 32 or 64 bits so replace it with a type with
a guaranteed size.
2013-02-11 19:57:49 +11:00
Chris Roberts
d7a161d943 Implemented CartChunk support for WAV files
Implement Cart Chunk support, in line with AES46.  The appropriate
standards document is available here:

http://www.aes.org/publications/standards/search.cfm?docID=41

Write tests to check consistency, check against reference application for
compatibility.

Only fully implemented with RIFF WAV format, though it might be applicable to
other formats.
2013-02-11 19:55:44 +11:00
Erik de Castro Lopo
1182c4d5dc Fix compiler warnings. 2012-10-12 00:31:36 +11:00
Erik de Castro Lopo
6040ad6a13 Add test for last commit. 2012-10-11 22:20:03 +11:00
Erik de Castro Lopo
1213c343ec tests/utils.tpl : Improve compare_*_or_die() functions. 2012-10-11 19:38:50 +11:00
Erik de Castro Lopo
80c47cb240 tests/ : Use the compression_size_test on FLAC as well. 2012-06-20 21:57:28 +10:00
Erik de Castro Lopo
249c9253a7 tests/utils.tpl : Rename gen_lowpass_noise_float() to gen_lowpass_signal_float(). 2012-06-20 21:30:07 +10:00
Erik de Castro Lopo
19f326f022 Rename vorbis_test.c -> compression_size_test.c. 2012-06-19 19:53:39 +10:00
Erik de Castro Lopo
8868115975 tests/string_test.c : Fix un-initialised char buffer. 2012-03-18 14:33:21 +11:00
Erik de Castro Lopo
9fa6c74223 Whitespace. 2012-03-18 12:06:16 +11:00
Erik de Castro Lopo
96b735a440 Reworking of custom chunk handling code. 2012-03-18 11:53:44 +11:00
Erik de Castro Lopo
5e10b3ccdf Whitespace and ChangeLog. 2012-03-17 20:20:02 +11:00
IOhannes m zmoelnig
5c36dcb54d added tests, whether the ID is properly set when retrieving chunks 2012-03-16 23:06:14 +01:00
IOhannes m zmoelnig
8c062feddd added test for writing/reading multiple chunks of the same ID 2012-03-16 22:16:29 +01:00
IOhannes m zmoelnig
45160f0fd3 adapted chunk_test to new chunk retrieval API 2012-03-16 21:44:39 +01:00
Erik de Castro Lopo
9f9f63a161 tests/fix_this.c : Fix potential int overflow. 2012-03-13 20:41:19 +11:00
Erik de Castro Lopo
e4f207d8a1 tests/pipe_test.tpl : Disable tests on OS/2. Thanks Dave Yeo. 2012-03-10 18:33:10 +11:00
Erik de Castro Lopo
8cf1567ac6 tests/ : Add tests for 20 and 24 bit ALAC/CAF files. 2012-03-10 10:59:15 +11:00
Erik de Castro Lopo
636a1c066a tests/ : Add tests for 32 bit ALAC/CAD files. 2012-03-06 20:22:50 +11:00
Erik de Castro Lopo
784ecd459c tests/floating_point_test.tpl : Add tests for 16 bit ALAC/CAF. 2012-03-06 19:15:45 +11:00
Erik de Castro Lopo
694a3c8eaa tests/chunk_test.c : Clean up error messages. 2012-03-05 01:12:54 +11:00
Erik de Castro Lopo
548771cd3a tests/write_read_test.tpl : Expand tests to cover ALAC. 2012-03-03 23:17:15 +11:00
Erik de Castro Lopo
20e43d929a tests/header_test.tpl : Printf format fixes. 2012-02-26 11:21:58 +11:00
Erik de Castro Lopo
d22a57b887 tests/utils.tpl : Use gnu_printf format checking with mingw compiler. 2012-02-26 11:21:24 +11:00
Erik de Castro Lopo
0bf397f9f7 tests/floating_point_test.tpl : Add initial test for sf_current_byterate(). 2012-02-25 23:01:21 +11:00
Erik de Castro Lopo
dabdc133d0 tests/string_test.c : Fix valgrind warnings. 2012-02-19 22:23:53 +11:00
Erik de Castro Lopo
911f8103bb tests/chunk_test.c : Extend custom chunk test. 2012-02-18 13:55:38 +11:00
Erik de Castro Lopo
518e3be6ef tests/ : Fix all printf format warnings. 2012-02-18 12:59:32 +11:00
Erik de Castro Lopo
f4da909c5d tests/utils.tpl : Add GCC specific testing for format string parameters for exit_if_true(). 2012-02-18 11:58:25 +11:00
Erik de Castro Lopo
8508ec5679 More whitespace and cstyle fixes. 2012-01-21 14:24:38 +11:00
Erik de Castro Lopo
18c1105981 Whitespace and cstyle fixes. 2012-01-20 22:46:13 +11:00
Erik de Castro Lopo
2ad57eb9b6 tests/string_test.c : Add tests for extending files in RDWR mode. 2012-01-20 22:46:13 +11:00
Erik de Castro Lopo
bbfd5150da tests/chunk_test.c : Fix error message. 2012-01-09 22:25:59 +11:00
Erik de Castro Lopo
6f26709560 Test CAF files with custom chunks. 2012-01-05 18:11:15 +11:00
Erik de Castro Lopo
5eb6df461f tests/test_wrapper.sh.in : Extent chunk_test to WAV. 2011-12-31 23:16:59 +11:00
Erik de Castro Lopo
03ca17d444 tests/chunk_test.c : Add WAVEX and RIFX tests. 2011-12-31 23:07:49 +11:00
Erik de Castro Lopo
4cde8e30f4 Add new test for custom chunks. 2011-12-31 20:04:06 +11:00
Erik de Castro Lopo
6e2f0b340d tests/ : Minor cleanups. 2011-12-19 20:40:08 +11:00
Erik de Castro Lopo
952d4e4cd7 Fix compiler warnings with latest MinGW cross compiler. 2011-10-28 19:15:22 +11:00
Erik de Castro Lopo
3dd9bc6d21 tests/write_read_test.tpl : Remove un-needed windows only truncate() implementation. 2011-10-06 21:23:53 +11:00
Erik de Castro Lopo
835f31e8de tests/write_read_test.tpl : Add tests for 32 bit PCM SD2 files. 2011-09-04 13:47:55 +10:00
Erik de Castro Lopo
24fac32d57 Add 'checkprograms' Make target. 2011-07-07 19:47:51 +10:00
Erik de Castro Lopo
603f0fb519 tests/utils.tpl : Clean up use of memset. 2011-07-06 20:12:10 +10:00
Erik de Castro Lopo
a121ba7963 tests/format_check_test.c : Fix compiler warnings. 2011-07-05 19:37:09 +10:00
Erik de Castro Lopo
caa74f89bb tests/test_wrapper.sh.in : Fix for ENABLE_EXPERIMENTAL_CODE mode. 2011-07-04 21:47:02 +10:00
Erik de Castro Lopo
58780bc2d4 tests/format_check_test.c : Add a test to for SF_FINFO format field validation. 2011-07-04 19:36:59 +10:00
Erik de Castro Lopo
b16c4a98d7 */Makefile.am : Use check_PROGRAMS instead of noinst_PROGRAMS where appropriate. 2011-05-18 06:34:39 +10:00
Erik de Castro Lopo
837e348993 tests/format_check_test.c : Fix segfault. 2011-05-01 02:42:30 +10:00
Erik de Castro Lopo
4d13639134 tests/format_check_test.c : Fix '==' where there should have been a '='. 2011-04-29 06:37:20 +10:00
Erik de Castro Lopo
d01c3c090a Hook new test program into build and test runner. 2011-04-25 20:07:36 +10:00
Erik de Castro Lopo
f27916e62a tests/format_check_test.c : New test program. 2011-04-25 20:05:45 +10:00
Erik de Castro Lopo
9b8d1e0f2f Fix a bunch of compiler warnings with gcc-4.6. 2011-03-28 18:43:05 +11:00
Erik de Castro Lopo
4f143688e7 tests/string_test.c : Add test for SF_STR_SOFTWARE segfault bug. 2011-03-25 19:13:51 +11:00
Erik de Castro Lopo
44594192ce tests/utils.tpl : Add NOT macro to util.h. 2011-03-25 18:58:12 +11:00
Erik de Castro Lopo
3345ba66f1 tests/cpp_test.cc : Fix a broken test (test segfaults). 2011-03-22 22:46:25 +11:00
Erik de Castro Lopo
86bf88790f tests/Makefile.am : Link lib to win32_test so testuite tarball works. 2011-03-22 09:41:04 +11:00
Erik de Castro Lopo
e0c6b3038c tests/test_wrapper.sh.in : Don't run cpp_test.exe when compiled with w64 compiler. 2011-03-21 09:12:40 +11:00
Erik de Castro Lopo
6b032a1b5f tests/utils.tpl : Move sf_info_(clear|setup) inside #ifdef SNDFILE_H. 2011-03-18 18:27:22 +11:00
Erik de Castro Lopo
912f139ed9 tests/(alaw|dwvw|ulaw)_test.c : Use functions sf_info_clear() and sf_info_setup(). 2011-03-15 22:10:10 +11:00
Erik de Castro Lopo
869a4d4e94 tests/utils.tpl : Add static inline functions sf_info_clear() and sf_info_setup(). 2011-03-15 20:37:58 +11:00
Erik de Castro Lopo
15b63dfca8 tests/cpp_test.cc : Add test for LPCWSTR version of the SndfileHandle constructor. 2011-01-27 20:51:09 +11:00
Erik de Castro Lopo
f209698448 Update copyright dates. 2011-01-19 21:36:56 +11:00
Erik de Castro Lopo
41c36ef340 tests/cpp_test.cc : Add tests for two new methods. Also supplied by Tim Blechmann. 2010-12-01 19:44:17 +11:00
Erik de Castro Lopo
5f5bbb50d4 tests/string_test.c : Add tests for SF_STR_GENRE and SF_STR_TRACKNUMBER. 2010-10-12 20:26:34 +11:00
Erik de Castro Lopo
9286b2c335 tests/pedantic-header-test.sh.in : Handle unusual values of CC environment variable. 2010-10-09 16:44:33 +11:00
Erik de Castro Lopo
c114f21ecf Makefile.am : Add *~ to CLEANFILES. 2010-10-06 22:16:41 +11:00
Erik de Castro Lopo
fe08ea435f tests/ : Whitespace fixes. 2010-10-04 22:25:33 +11:00
Erik de Castro Lopo
229e66bfb0 Tweak SF_BROADCAST_INFO tests. 2010-10-03 20:48:43 +11:00
Erik de Castro Lopo
d3d2b397f0 tests/pedantic-header-test.sh.in : Exit 0 if the source file isn't present. 2010-09-30 07:46:49 +10:00
Erik de Castro Lopo
9fc3c09c85 tests/write_read_test.tpl : Don't allow SDS files to have a long frame count. 2010-09-29 20:41:03 +10:00
Erik de Castro Lopo
8deeb575a8 Fix a bunch of minor issues found using static analysis. 2010-09-10 18:33:27 +10:00
Erik de Castro Lopo
a5bec997a2 tests/pedantic-header-test.sh.in : Fix out of tree builds. 2010-04-25 08:57:01 +10:00
Erik de Castro Lopo
fac9e4a9d7 tests/pedantic-header-test.sh.in : Fix 'make distcheck'. 2010-04-23 21:46:00 +10:00
Erik de Castro Lopo
79eb5e5102 tests/pedantic-header-test.sh.in : Make it work when doing 'make distcheck'. 2010-04-21 19:13:51 +10:00
Erik de Castro Lopo
57dc07f947 tests/sfversion.c : Remove cruft. 2010-04-21 19:13:23 +10:00
Erik de Castro Lopo
1b5335b0ff tests/*.sh.in : Add copyright notices. 2010-04-21 18:25:30 +10:00
Erik de Castro Lopo
66f6e6cae7 Hook pedantic-header-test into test suite. 2010-04-21 18:17:45 +10:00
Erik de Castro Lopo
d1484cf543 tests/pedantic-header-test.sh.in : New file to test whether sndfile.h can be compiled with gcc's -pedantic flag. 2010-04-21 18:13:26 +10:00
Erik de Castro Lopo
b7f1dde2d6 tests/test_wrapper.sh.in : Add rdwr_test to the test wrapper script. 2010-02-28 14:14:23 +11:00
Erik de Castro Lopo
0d4302b0ef tests/rdwr_test.(def|tpl) : Add new test program and hook into build. 2010-02-28 13:52:11 +11:00
Erik de Castro Lopo
08346be458 tests/utils.tpl : Add functions test_read_raw_or_die and test_write_raw_or_die. 2010-02-28 13:23:56 +11:00
Erik de Castro Lopo
66e72fb912 Disable pipe_test if pipe() and waitpid() aren't available. 2009-12-28 08:23:47 +11:00
Erik de Castro Lopo
ea62c5083d Merge from -dev. 2009-12-11 05:48:36 +11:00
Erik de Castro Lopo
ea3e2a2bc9 tests/error_test.c : Don't terminate when sf_close() returns zero in error_close_test(). 2009-12-08 21:29:42 +11:00
Erik de Castro Lopo
3083d46d8b tests/win32_test.c : Add a new test. 2009-12-01 19:06:02 +11:00
Erik de Castro Lopo
a5438d79ac tests/multi_file_test.c : Fix file creation flags on windows. Thanks to Bruce Sharpe. 2009-12-01 18:08:29 +11:00
Erik de Castro Lopo
1a66b22ca0 Minor OS/2 tweaks as suggested by David Yeo. 2009-12-01 07:21:36 +11:00
Erik de Castro Lopo
29740441d1 tests/locale_test.c : Correct usage of ENABLE_SNDFILE_WINDOWS_PROTOTYPES. 2009-11-22 07:10:35 +11:00
Erik de Castro Lopo
40d5267f43 tests/virtual_io_test.c : Add a PAF/PCM_24 test and verify the file length is not negative immediately after openning the file for write. 2009-11-16 20:04:26 +11:00
Erik de Castro Lopo
197273486c Merge from -dev branch. 2009-10-18 21:16:32 +11:00
Erik de Castro Lopo
cbe9da2c7b tests/test_wrapper.sh.in : Don't run cpp_test on x86_64-w64-mingw32. 2009-10-05 12:14:15 +11:00
Erik de Castro Lopo
997740916f tests/utils.tpl : On windows, make sure the open() function doesn't get called with a third parameter of 0 which fails for no good reason. 2009-09-28 18:46:34 +10:00
Erik de Castro Lopo
6a6d088305 Update to allow all tests to be gathered up into a testsuite tarball and then be run using this script. 2009-09-27 11:50:12 +10:00
Erik de Castro Lopo
b206605beb tests/locale_test.c : Add a wchar_test() to test sf_wchar_open(). 2009-09-26 22:24:01 +10:00
Erik de Castro Lopo
8d505f0d5b tests/locale_test.c : Unlink file before changing back to old locale. 2009-09-25 21:14:46 +10:00
Erik de Castro Lopo
43f72b12cc tests/locale_test.c : Update to work with xx_XX.UTF-8 style locales. Refactoring. 2009-09-23 20:02:35 +10:00
Erik de Castro Lopo
37a36e7746 Remove WIN32 snprintf #define. 2009-09-19 20:30:58 +10:00
Erik de Castro Lopo
97ca21cd46 Run peak_chunk_test on CAF files. 2009-09-16 20:14:54 +10:00
Erik de Castro Lopo
661fa46a30 tests/win32_ordinal_test.c : Look for stuff in current directory as well. 2009-09-16 18:30:24 +10:00
Erik de Castro Lopo
f07916361d tests/test_wrapper.sh.in : Simplify tests. 2009-09-15 21:37:14 +10:00
Erik de Castro Lopo
3fdcfaac9e tests/command_test.c : Add a test for BEXT in RF64. 2009-08-30 12:14:50 +10:00
Erik de Castro Lopo
e0607620f0 Update channel map tests. 2009-05-27 20:49:54 +10:00
Erik de Castro Lopo
9642444462 tests/command_test.c : Update channel_map_test() function so WAV test passes. 2009-05-24 08:33:20 +10:00
Erik de Castro Lopo
5b2779996c tests/utils.tpl : Add check of sf_error to test_open_file_or_die(). 2009-04-12 21:38:59 +10:00
Erik de Castro Lopo
9380ad3f9e tests/stdin_test.c : Check psf->error after opening file. 2009-04-12 15:28:39 +10:00
Erik de Castro Lopo
b99995bef5 tests/ : Cleanup output. 2009-04-11 11:30:42 +10:00
Erik de Castro Lopo
12a46a4785 Bunch of minor fixes. 2009-03-24 19:58:48 +11:00
Erik de Castro Lopo
cf4859c221 tests/sfversion.c : Test function sf_version_string. 2009-03-17 14:11:18 +11:00
Erik de Castro Lopo
f2e1e833de tests/pcm_test.tpl : Improve output. 2009-03-17 03:09:10 +11:00
Erik de Castro Lopo
85c6b26122 tests/vorbis_test.c : Relax test slighly to allow test to pass on more CPUs etc. 2009-03-04 11:44:42 +11:00
Erik de Castro Lopo
56eea7e1e4 tests/win32_test.c : Fix resource leak. 2009-03-01 20:47:32 +11:00
Erik de Castro Lopo
c86546efd9 tests/win32_test.c : Don't use sprintf, even on windows. 2009-02-24 11:04:46 +11:00
Erik de Castro Lopo
7af1f475ce tests/win32_test.c : Add missing close on file descriptor. 2009-02-22 16:53:48 +11:00
Erik de Castro Lopo
d3f52ad480 tests/test_wrapper.sh.in : Add 'set -e' so the script exits on error. 2009-02-22 13:08:37 +11:00
Erik de Castro Lopo
12180c5bb3 tests/*.c : Don't include un-needed headers. 2009-02-22 12:39:48 +11:00
Erik de Castro Lopo
23d8864739 tests/Makefile.am : Replace all tests with a single invocation of the test wrapper script. 2009-02-11 09:31:54 +11:00
Erik de Castro Lopo
925b00fac0 Add file tests/test_wrapper.sh.in. 2009-02-11 09:31:16 +11:00
Erik de Castro Lopo
a38e0b105e Update copyright notices. 2009-02-07 15:20:17 +11:00
Erik de Castro Lopo
e9a1817530 tests/string_test.c : Add test for RDWR mode where the file ends up shorter than when it was opened. 2008-12-14 20:19:44 +11:00
Erik de Castro Lopo
e12ea8acfd tests/win32_ordinal_test.c : Update tests symbol file changes. 2008-11-14 21:46:37 +11:00
Erik de Castro Lopo
0c1e963eda tests/command_test.c : Add test to detect if coding history is truncated. 2008-10-28 06:56:16 +11:00
Erik de Castro Lopo
90dce5560a tests/command_test.c : Add broadcast_coding_history_size test. 2008-10-27 06:16:32 +11:00
Erik de Castro Lopo
5992144307 tests/error_test.c : Fix failure behaviour in error_number_test. 2008-10-26 20:19:25 +11:00
Erik de Castro Lopo
8b4361bb6b tests/command_test.c : Rearrange prototypes. 2008-10-26 17:04:21 +11:00
Erik de Castro Lopo
1bb50bd170 tests/Makefile.am : Automake 1.10 MinGW cross compiling fixes. 2008-10-20 23:05:09 +11:00
Erik de Castro Lopo
10ca1fd3d1 tests : Fix gcc-4.3 compiler warnings. 2008-10-19 16:06:42 +11:00
Erik de Castro Lopo
797f33196c tests/command_test.c : Fix valgrind test. 2008-10-19 16:01:10 +11:00
Erik de Castro Lopo
703b9bcc32 tests/Makefile.am : Disable string tests for RF64. 2008-10-14 10:06:10 +11:00
Erik de Castro Lopo
019dbf5056 Merge from -mdev branch. 2008-10-14 09:24:33 +11:00
Erik de Castro Lopo
2b01bc02f1 tests/command_test.c : Add test function instrument_rw_test, but don't hook it into the testing yet. 2008-10-13 20:07:19 +11:00
Erik de Castro Lopo
5b754eba25 tests/command_test.c : Fix false failure. 2008-10-10 06:50:10 +11:00
Erik de Castro Lopo
ca75132a34 tests/command_test.c : Improve error reporting when '\0' is found in coding history. 2008-10-10 06:05:28 +11:00