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