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