if(0 != test_bitbuffer())
return 1;
- if(0 != test_metadata(argv[0]))
+ if(0 != test_metadata())
return 1;
return 0;
#include <stdio.h>
extern int test_metadata_object();
-extern int test_metadata_file_manipulation(const char *progname);
+extern int test_metadata_file_manipulation();
-int test_metadata(const char *progname)
+int test_metadata()
{
if(0 != test_metadata_object())
return 1;
- if(0 != test_metadata_file_manipulation(progname))
+ if(0 != test_metadata_file_manipulation())
return 1;
printf("\nPASSED!\n");
#ifndef FLAC__TEST_UNIT_METADATA_H
#define FLAC__TEST_UNIT_METADATA_H
-int test_metadata(const char *progname);
+int test_metadata();
#endif
LD_LIBRARY_PATH=../src/libFLAC/.libs:../obj/lib:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH
PATH=../src/test_unit:../obj/bin:$PATH
+export PATH
-# We use the whole path to test_unit so it can find itself. It uses it's own
-# binary as a dummy source for creating a test FLAC file so it can work on the
-# metadata.
-if `which test_unit` ; then : ; else
+if test_unit ; then : ; else
echo "ERROR during test_unit" 1>&2
exit 1
fi