xref: /freebsd/contrib/file/tests/Makefile.am (revision 271171e0)
1check_PROGRAMS = test
2test_LDADD = $(top_builddir)/src/libmagic.la
3test_CPPFLAGS = -I$(top_builddir)/src
4
5EXTRA_DIST = \
6android-vdex-1.result \
7android-vdex-1.testfile \
8android-vdex-2.result \
9android-vdex-2.testfile \
10arj.result \
11arj.testfile \
12CVE-2014-1943.result \
13CVE-2014-1943.testfile \
14JW07022A.mp3.result \
15JW07022A.mp3.testfile \
16bcachefs.result \
17bcachefs.testfile \
18cl8m8ocofedso.result \
19cl8m8ocofedso.testfile \
20escapevel.result \
21escapevel.testfile \
22ext4.result \
23ext4.testfile \
24fit-map-data.result \
25fit-map-data.testfile \
26gedcom.result \
27gedcom.testfile \
28hddrawcopytool.result \
29hddrawcopytool.testfile \
30issue311docx.result \
31issue311docx.testfile \
32issue359xlsx.result \
33issue359xlsx.testfile \
34json1.result \
35json1.testfile \
36json2.result \
37json2.testfile \
38json3.result \
39json3.testfile \
40json4.result \
41json4.testfile \
42json5.result \
43json5.testfile \
44matilde.arm.result \
45matilde.arm.testfile \
46pcjr.result \
47pcjr.testfile \
48pgp-binary-key-v2-phil.result \
49pgp-binary-key-v2-phil.testfile \
50pgp-binary-key-v3-lutz.result \
51pgp-binary-key-v3-lutz.testfile \
52pgp-binary-key-v4-dsa.result \
53pgp-binary-key-v4-dsa.testfile \
54pgp-binary-key-v4-ecc-no-userid-secret.result \
55pgp-binary-key-v4-ecc-no-userid-secret.testfile \
56pgp-binary-key-v4-ecc-secret-key.result \
57pgp-binary-key-v4-ecc-secret-key.testfile \
58pgp-binary-key-v4-rsa-key.result \
59pgp-binary-key-v4-rsa-key.testfile \
60pgp-binary-key-v4-rsa-no-userid-secret.result \
61pgp-binary-key-v4-rsa-no-userid-secret.testfile \
62pgp-binary-key-v4-rsa-secret-key.result \
63pgp-binary-key-v4-rsa-secret-key.testfile \
64regex-eol.magic \
65regex-eol.result \
66regex-eol.testfile \
67uf2.result \
68uf2.testfile \
69zstd-3-skippable-frames.result \
70zstd-dictionary-0.result \
71zstd-dictionary-1.result \
72zstd-dictionary-2.result \
73zstd-skippable-frame-0.result \
74zstd-skippable-frame-4.result \
75zstd-skippable-frame-8.result \
76zstd-skippable-frame-C.result \
77zstd-v0.2-FF.result \
78zstd-v0.2-FF.testfile \
79zstd-v0.3-FF.result \
80zstd-v0.3-FF.testfile \
81zstd-v0.4-FF.result \
82zstd-v0.4-FF.testfile \
83zstd-v0.5-FF.result \
84zstd-v0.5-FF.testfile \
85zstd-v0.6-FF.result \
86zstd-v0.6-FF.testfile \
87zstd-v0.7-00.result \
88zstd-v0.7-21.result \
89zstd-v0.7-21.testfile \
90zstd-v0.7-22.result \
91zstd-v0.7-22.testfile \
92zstd-v0.8-00.result \
93zstd-v0.8-01.result \
94zstd-v0.8-01.testfile \
95zstd-v0.8-02.result \
96zstd-v0.8-02.testfile \
97zstd-v0.8-03.result \
98zstd-v0.8-03.testfile \
99zstd-v0.8-16.result \
100zstd-v0.8-16.testfile \
101zstd-v0.8-20.result \
102zstd-v0.8-20.testfile \
103zstd-v0.8-21.result \
104zstd-v0.8-21.testfile \
105zstd-v0.8-22.result \
106zstd-v0.8-22.testfile \
107zstd-v0.8-23.result \
108zstd-v0.8-23.testfile \
109zstd-v0.8-F4.result \
110zstd-v0.8-F4.testfile \
111zstd-v0.8-FF.result \
112zstd-v0.8-FF.testfile
113
114T = $(top_srcdir)/tests
115check-local:
116	MAGIC=$(top_builddir)/magic/magic ./test
117	set -e; \
118	for i in $T/*.testfile; do \
119		echo Running test: $$i; \
120		if [ -f $${i%%.testfile}.magic ]; then \
121			m=$${i%%.testfile}.magic; \
122		else \
123			m=$(top_builddir)/magic/magic; \
124		fi; \
125		TZ=UTC MAGIC=$$m ./test $$i $${i%%.testfile}.result; \
126	done
127