doc: move @shortcontents and @contents from end to start
[platform/upstream/coreutils.git] / tests / Makefile.am
1 ## Process this file with automake to produce Makefile.in -*-Makefile-*-.
2
3 # Sort in traditional ASCII order, regardless of the current locale;
4 # otherwise we may get into trouble with distinct strings that the
5 # current locale considers to be equal.
6 ASSORT = LC_ALL=C sort
7
8 EXTRA_DIST =            \
9   Coreutils.pm          \
10   CuTmpdir.pm           \
11   README                \
12   check.mk              \
13   envvar-check          \
14   lang-default          \
15   other-fs-tmpdir       \
16   require-perl          \
17   sample-test           \
18   setgid-check          \
19   test-lib.sh           \
20   $(pr_data)
21
22 root_tests =                                    \
23   chown/basic                                   \
24   cp/cp-a-selinux                               \
25   cp/preserve-gid                               \
26   cp/special-bits                               \
27   ls/capability                                 \
28   ls/nameless-uid                               \
29   misc/chcon                                    \
30   misc/selinux                                  \
31   misc/truncate-owned-by-other                  \
32   mkdir/writable-under-readonly                 \
33   mv/sticky-to-xpart                            \
34   rm/fail-2eperm                                \
35   rm/no-give-up                                 \
36   rm/one-file-system                            \
37   tail-2/append-only                            \
38   touch/now-owned-by-other
39
40 .PHONY: check-root
41 check-root:
42         $(MAKE) check TESTS='$(root_tests)'
43
44 check-recursive: root-hint
45
46 # Advertise `check-root' target.
47 .PHONY: root-hint
48 root-hint:
49         @echo '***********************************************************'
50         @echo "NOTICE: Some tests may be run only as root."
51         @echo "  See the 'Running tests as root' section in README."
52         @echo '***********************************************************'
53
54 EXTRA_DIST += $(TESTS)
55
56 # Do not choose a name that is a shell keyword like 'if', or a
57 # commonly-used utility like 'cat' or 'test', as the name of a test.
58 # Otherwise, VPATH builds will fail on hosts like Solaris, since they
59 # will expand 'if test ...' to 'if .../test ...', and the '.../test'
60 # will execute the test script rather than the standard utility.
61
62 # Notes on the ordering of these tests:
63 # Place early in the list tests of the tools that
64 # are most commonly used in test scripts themselves.
65 # E.g., nearly every test script uses rm and chmod.
66 # help-version comes early because it's a basic sanity test.
67 # Put seq early, since lots of other tests use it.
68 # Put tests that sleep early, but not all together, so in parallel builds
69 # they share time with tests that burn CPU, not with others that sleep.
70 # Put head-elide-tail early, because it's long-running.
71
72 TESTS =                                         \
73   misc/help-version                             \
74   misc/invalid-opt                              \
75   rm/ext3-perf                                  \
76   rm/cycle                                      \
77   chmod/no-x                                    \
78   chgrp/basic                                   \
79   rm/dangling-symlink                           \
80   misc/ls-time                                  \
81   rm/deep-1                                     \
82   rm/deep-2                                     \
83   rm/dir-no-w                                   \
84   rm/dir-nonrecur                               \
85   rm/dot-rel                                    \
86   rm/isatty                                     \
87   rm/empty-inacc                                \
88   rm/empty-name                                 \
89   rm/f-1                                        \
90   rm/fail-eacces                                \
91   rm/fail-eperm                                 \
92   tail-2/assert                                 \
93   rm/hash                                       \
94   rm/i-1                                        \
95   rm/i-never                                    \
96   rm/i-no-r                                     \
97   tail-2/infloop-1                              \
98   rm/ignorable                                  \
99   rm/inaccessible                               \
100   rm/interactive-always                         \
101   rm/interactive-once                           \
102   rm/ir-1                                       \
103   rm/r-1                                        \
104   rm/r-2                                        \
105   rm/r-3                                        \
106   rm/r-4                                        \
107   rm/readdir-bug                                \
108   rm/rm1                                        \
109   touch/empty-file                              \
110   rm/rm2                                        \
111   rm/rm3                                        \
112   rm/rm4                                        \
113   rm/rm5                                        \
114   rm/sunos-1                                    \
115   rm/unread2                                    \
116   rm/unread3                                    \
117   rm/unreadable                                 \
118   rm/v-slash                                    \
119   chgrp/default-no-deref                        \
120   chgrp/deref                                   \
121   chgrp/no-x                                    \
122   chgrp/posix-H                                 \
123   chgrp/recurse                                 \
124   misc/ptx                                      \
125   misc/test                                     \
126   misc/seq                                      \
127   misc/seq-long-double                                  \
128   misc/head                                     \
129   misc/head-elide-tail                          \
130   tail-2/tail-n0f                               \
131   misc/ls-misc                                  \
132   misc/date                                     \
133   misc/ptx-overrun                              \
134   misc/xstrtol                                  \
135   misc/od                                       \
136   misc/mktemp                                   \
137   misc/arch                                     \
138   misc/pr                                       \
139   misc/join                                     \
140   pr/pr-tests                                   \
141   misc/df-P                                     \
142   misc/pwd-unreadable-parent                    \
143   misc/chcon-fail                               \
144   misc/cut                                      \
145   misc/wc                                       \
146   misc/wc-files0-from                           \
147   misc/wc-files0                                \
148   misc/cat-proc                                 \
149   misc/base64                                   \
150   misc/basename                                 \
151   misc/close-stdout                             \
152   misc/comm                                     \
153   misc/csplit                                   \
154   misc/date-sec                                 \
155   misc/dircolors                                \
156   misc/df                                       \
157   misc/dirname                                  \
158   misc/expand                                   \
159   misc/expr                                     \
160   misc/factor                                   \
161   misc/false-status                             \
162   misc/fmt                                      \
163   misc/fmt-long-line                            \
164   misc/fold                                     \
165   misc/groups-dash                              \
166   misc/groups-version                           \
167   misc/head-c                                   \
168   misc/head-pos                                 \
169   misc/id-context                               \
170   misc/md5sum                                   \
171   misc/md5sum-newline                           \
172   misc/mknod                                    \
173   misc/nice                                     \
174   misc/nl                                       \
175   misc/nohup                                    \
176   misc/od-N                                     \
177   misc/od-multiple-t                            \
178   misc/od-x8                                    \
179   misc/paste                                    \
180   misc/pathchk1                                 \
181   misc/printf                                   \
182   misc/printf-cov                               \
183   misc/printf-hex                               \
184   misc/printf-surprise                          \
185   misc/pwd-long                                 \
186   misc/readlink-fp-loop                         \
187   misc/runcon-no-reorder                        \
188   misc/sha1sum                                  \
189   misc/sha1sum-vec                              \
190   misc/sha224sum                                \
191   misc/sha256sum                                \
192   misc/sha384sum                                \
193   misc/sha512sum                                \
194   misc/shred-exact                              \
195   misc/shred-remove                             \
196   misc/shuf                                     \
197   misc/sort                                     \
198   misc/sort-compress                            \
199   misc/sort-files0-from                         \
200   misc/sort-merge                               \
201   misc/sort-rand                                \
202   misc/sort-version                             \
203   misc/split-a                                  \
204   misc/split-fail                               \
205   misc/split-l                                  \
206   misc/stat-fmt                                 \
207   misc/stat-printf                              \
208   misc/stty                                     \
209   misc/stty-invalid                             \
210   misc/stty-row-col                             \
211   misc/sum                                      \
212   misc/sum-sysv                                 \
213   misc/tac                                      \
214   misc/tac-continue                             \
215   misc/tail                                     \
216   misc/tee                                      \
217   misc/tee-dash                                 \
218   misc/test-diag                                \
219   misc/timeout                                  \
220   misc/timeout-parameters                       \
221   misc/tr                                       \
222   misc/truncate-dangling-symlink                \
223   misc/truncate-dir-fail                        \
224   misc/truncate-fail-diag                       \
225   misc/truncate-fifo                            \
226   misc/truncate-no-create-missing               \
227   misc/truncate-overflow                        \
228   misc/truncate-parameters                      \
229   misc/truncate-relative                        \
230   misc/tsort                                    \
231   misc/tty-eof                                  \
232   misc/unexpand                                 \
233   misc/uniq                                     \
234   chmod/c-option                                \
235   chmod/equal-x                                 \
236   chmod/equals                                  \
237   chmod/inaccessible                            \
238   chmod/octal                                   \
239   chmod/setgid                                  \
240   chmod/thru-dangling                           \
241   chmod/umask-x                                 \
242   chmod/usage                                   \
243   chown/deref                                   \
244   chown/preserve-root                           \
245   chown/separator                               \
246   cp/abuse                                      \
247   cp/acl                                        \
248   cp/backup-1                                   \
249   cp/backup-dir                                 \
250   cp/backup-is-src                              \
251   cp/cp-HL                                      \
252   cp/cp-deref                                   \
253   cp/cp-i                                       \
254   cp/cp-mv-backup                               \
255   cp/cp-parents                                 \
256   cp/deref-slink                                \
257   cp/dir-rm-dest                                \
258   cp/dir-slash                                  \
259   cp/dir-vs-file                                \
260   cp/existing-perm-race                         \
261   cp/fail-perm                                  \
262   cp/file-perm-race                             \
263   cp/into-self                                  \
264   cp/link                                       \
265   cp/link-heap                                  \
266   cp/link-no-deref                              \
267   cp/link-preserve                              \
268   cp/no-deref-link1                             \
269   cp/no-deref-link2                             \
270   cp/no-deref-link3                             \
271   cp/parent-perm                                \
272   cp/parent-perm-race                           \
273   cp/perm                                       \
274   cp/preserve-2                                 \
275   cp/proc-zero-len                              \
276   cp/r-vs-symlink                               \
277   cp/same-file                                  \
278   cp/slink-2-slink                              \
279   cp/sparse                                     \
280   cp/special-f                                  \
281   cp/src-base-dot                               \
282   cp/symlink-slash                              \
283   cp/thru-dangling                              \
284   dd/misc                                       \
285   dd/not-rewound                                \
286   dd/reblock                                    \
287   dd/skip-seek                                  \
288   dd/skip-seek2                                 \
289   dd/unblock-sync                               \
290   df/total-verify                               \
291   du/2g                                         \
292   du/8gb                                        \
293   du/basic                                      \
294   du/deref                                      \
295   du/deref-args                                 \
296   du/exclude                                    \
297   du/fd-leak                                    \
298   du/files0-from                                \
299   du/hard-link                                  \
300   du/inacc-dest                                 \
301   du/inacc-dir                                  \
302   du/inaccessible-cwd                           \
303   du/long-from-unreadable                       \
304   du/long-sloop                                 \
305   du/no-deref                                   \
306   du/no-x                                       \
307   du/one-file-system                            \
308   du/restore-wd                                 \
309   du/slash                                      \
310   du/slink                                      \
311   du/trailing-slash                             \
312   du/two-args                                   \
313   install/basic-1                               \
314   install/create-leading                        \
315   install/d-slashdot                            \
316   install/strip-program                         \
317   install/trap                                  \
318   ln/backup-1                                   \
319   ln/hard-backup                                \
320   ln/misc                                       \
321   ln/sf-1                                       \
322   ln/target-1                                   \
323   ls/color-dtype-dir                            \
324   ls/dangle                                     \
325   ls/dired                                      \
326   ls/file-type                                  \
327   ls/follow-slink                               \
328   ls/hardlink                                   \
329   ls/infloop                                    \
330   ls/inode                                      \
331   ls/m-option                                   \
332   ls/no-arg                                     \
333   ls/no-cap                                     \
334   ls/proc-selinux-segfault                      \
335   ls/recursive                                  \
336   ls/rt-1                                       \
337   ls/stat-dtype                                 \
338   ls/stat-failed                                \
339   ls/stat-free-symlinks                         \
340   ls/stat-vs-dirent                             \
341   ls/symlink-slash                              \
342   ls/x-option                                   \
343   mkdir/p-1                                     \
344   mkdir/p-2                                     \
345   mkdir/p-3                                     \
346   mkdir/p-slashdot                              \
347   mkdir/p-thru-slink                            \
348   mkdir/p-v                                     \
349   mkdir/parents                                 \
350   mkdir/perm                                    \
351   mkdir/selinux                                 \
352   mkdir/special-1                               \
353   mkdir/t-slash                                 \
354   mv/acl                                        \
355   mv/atomic                                     \
356   mv/atomic2                                    \
357   mv/backup-dir                                 \
358   mv/backup-is-src                              \
359   mv/childproof                                 \
360   mv/diag                                       \
361   mv/dir-file                                   \
362   mv/dir2dir                                    \
363   mv/dup-source                                 \
364   mv/force                                      \
365   mv/hard-2                                     \
366   mv/hard-3                                     \
367   mv/hard-4                                     \
368   mv/hard-link-1                                \
369   mv/hard-verbose                               \
370   mv/i-1                                        \
371   mv/i-2                                        \
372   mv/i-3                                        \
373   mv/i-4                                        \
374   mv/i-5                                        \
375   mv/i-link-no                                  \
376   mv/into-self                                  \
377   mv/into-self-2                                \
378   mv/into-self-3                                \
379   mv/into-self-4                                \
380   mv/leak-fd                                    \
381   mv/mv-special-1                               \
382   mv/no-target-dir                              \
383   mv/part-fail                                  \
384   mv/part-hardlink                              \
385   mv/part-rename                                \
386   mv/part-symlink                               \
387   mv/partition-perm                             \
388   mv/perm-1                                     \
389   mv/reply-no                                   \
390   mv/to-symlink                                 \
391   mv/trailing-slash                             \
392   mv/update                                     \
393   readlink/can-e                                \
394   readlink/can-f                                \
395   readlink/can-m                                \
396   readlink/rl-1                                 \
397   rmdir/fail-perm                               \
398   rmdir/ignore                                  \
399   rmdir/t-slash                                 \
400   tail-2/assert-2                               \
401   tail-2/big-4gb                                \
402   tail-2/proc-ksyms                             \
403   tail-2/start-middle                           \
404   touch/dangling-symlink                        \
405   touch/dir-1                                   \
406   touch/fail-diag                               \
407   touch/fifo                                    \
408   touch/no-create-missing                       \
409   touch/no-rights                               \
410   touch/not-owner                               \
411   touch/obsolescent                             \
412   touch/read-only                               \
413   touch/relative                                \
414   $(root_tests)
415
416 pr_data =                                       \
417   pr/0F                                         \
418   pr/0FF                                        \
419   pr/0FFnt                                      \
420   pr/0FFt                                       \
421   pr/0FnFnt                                     \
422   pr/0FnFt                                      \
423   pr/0Fnt                                       \
424   pr/0Ft                                        \
425   pr/2-S_f-t_notab                              \
426   pr/2-Sf-t_notab                               \
427   pr/2f-t_notab                                 \
428   pr/2s_f-t_notab                               \
429   pr/2s_w60f-t_nota                             \
430   pr/2sf-t_notab                                \
431   pr/2sw60f-t_notab                             \
432   pr/2w60f-t_notab                              \
433   pr/3-0F                                       \
434   pr/3-5l24f-t                                  \
435   pr/3-FF                                       \
436   pr/3a2l17-FF                                  \
437   pr/3a3f-0F                                    \
438   pr/3a3l15-t                                   \
439   pr/3a3l15f-t                                  \
440   pr/3b2l17-FF                                  \
441   pr/3b3f-0F                                    \
442   pr/3b3f-0FF                                   \
443   pr/3b3f-FF                                    \
444   pr/3b3l15-t                                   \
445   pr/3b3l15f-t                                  \
446   pr/3f-0F                                      \
447   pr/3f-FF                                      \
448   pr/3l24-t                                     \
449   pr/3l24f-t                                    \
450   pr/3ml24-FF                                   \
451   pr/3ml24-t                                    \
452   pr/3ml24-t-FF                                 \
453   pr/3ml24f-t                                   \
454   pr/4-7l24-FF                                  \
455   pr/4l24-FF                                    \
456   pr/FF                                         \
457   pr/FFn                                        \
458   pr/FFtn                                       \
459   pr/FnFn                                       \
460   pr/Ja3l24f-lm                                 \
461   pr/Jb3l24f-lm                                 \
462   pr/Jml24f-lm-lo                               \
463   pr/W-72l24f-ll                                \
464   pr/W20l24f-ll                                 \
465   pr/W26l24f-ll                                 \
466   pr/W27l24f-ll                                 \
467   pr/W28l24f-ll                                 \
468   pr/W35Ja3l24f-lm                              \
469   pr/W35Jb3l24f-lm                              \
470   pr/W35Jml24f-lmlo                             \
471   pr/W35a3l24f-lm                               \
472   pr/W35b3l24f-lm                               \
473   pr/W35ml24f-lm-lo                             \
474   pr/W72Jl24f-ll                                \
475   pr/a2l15-FF                                   \
476   pr/a2l17-FF                                   \
477   pr/a3-0F                                      \
478   pr/a3f-0F                                     \
479   pr/a3f-0FF                                    \
480   pr/a3f-FF                                     \
481   pr/a3l15-t                                    \
482   pr/a3l15f-t                                   \
483   pr/a3l24f-lm                                  \
484   pr/b2l15-FF                                   \
485   pr/b2l17-FF                                   \
486   pr/b3-0F                                      \
487   pr/b3f-0F                                     \
488   pr/b3f-0FF                                    \
489   pr/b3f-FF                                     \
490   pr/b3l15-t                                    \
491   pr/b3l15f-t                                   \
492   pr/b3l24f-lm                                  \
493   pr/l24-FF                                     \
494   pr/l24-t                                      \
495   pr/l24f-t                                     \
496   pr/loli                                       \
497   pr/ml20-FF-t                                  \
498   pr/ml24-FF                                    \
499   pr/ml24-t                                     \
500   pr/ml24-t-FF                                  \
501   pr/ml24f-0F                                   \
502   pr/ml24f-lm-lo                                \
503   pr/ml24f-t                                    \
504   pr/ml24f-t-0F                                 \
505   pr/n+2-5l24f-0FF                              \
506   pr/n+2l24f-0FF                                \
507   pr/n+2l24f-bl                                 \
508   pr/n+3-7l24-FF                                \
509   pr/n+3l24f-0FF                                \
510   pr/n+3l24f-bl                                 \
511   pr/n+3ml20f-bl-FF                             \
512   pr/n+3ml24f-bl-tn                             \
513   pr/n+3ml24f-tn-bl                             \
514   pr/n+4-8a2l17-FF                              \
515   pr/n+4b2l17f-0FF                              \
516   pr/n+5-8b3l17f-FF                             \
517   pr/n+5a3l13f-0FF                              \
518   pr/n+6a2l17-FF                                \
519   pr/n+6b3l13f-FF                               \
520   pr/n+7l24-FF                                  \
521   pr/n+8l20-FF                                  \
522   pr/nJml24f-lmlmlo                             \
523   pr/nJml24f-lmlolm                             \
524   pr/nN1+3l24f-bl                               \
525   pr/nN15l24f-bl                                \
526   pr/nSml20-bl-FF                               \
527   pr/nSml20-t-t-FF                              \
528   pr/nSml20-t-tFFFF                             \
529   pr/nSml24-bl-FF                               \
530   pr/nSml24-t-t-FF                              \
531   pr/nSml24-t-tFFFF                             \
532   pr/nl24f-bl                                   \
533   pr/o3Jml24f-lm-lo                             \
534   pr/o3a3Sl24f-tn                               \
535   pr/o3a3Snl24f-tn                              \
536   pr/o3a3l24f-tn                                \
537   pr/o3b3Sl24f-tn                               \
538   pr/o3b3Snl24f-tn                              \
539   pr/o3b3l24f-tn                                \
540   pr/o3mSl24f-bl-tn                             \
541   pr/o3mSnl24fbltn                              \
542   pr/o3ml24f-bl-tn                              \
543   pr/t-0FF                                      \
544   pr/t-FF                                       \
545   pr/t-bl                                       \
546   pr/t-t                                        \
547   pr/tFFn                                       \
548   pr/tFFt                                       \
549   pr/tFFt-bl                                    \
550   pr/tFFt-ll                                    \
551   pr/tFFt-lm                                    \
552   pr/tFnFt                                      \
553   pr/t_notab                                    \
554   pr/t_tab                                      \
555   pr/t_tab_                                     \
556   pr/ta3-0FF                                    \
557   pr/ta3-FF                                     \
558   pr/tb3-0FF                                    \
559   pr/tb3-FF                                     \
560   pr/tn                                         \
561   pr/tn2e5o3-t_tab                              \
562   pr/tn2e8-t_tab                                \
563   pr/tn2e8o3-t_tab                              \
564   pr/tn_2e8-t_tab                               \
565   pr/tn_2e8S-t_tab                              \
566   pr/tne8-t_tab                                 \
567   pr/tne8o3-t_tab                               \
568   pr/tt-0FF                                     \
569   pr/tt-FF                                      \
570   pr/tt-bl                                      \
571   pr/tt-t                                       \
572   pr/tta3-0FF                                   \
573   pr/tta3-FF                                    \
574   pr/ttb3-0FF                                   \
575   pr/ttb3-FF                                    \
576   pr/w72l24f-ll
577
578 AUTOMAKE_OPTIONS =
579 include $(srcdir)/check.mk