aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/xargs/tests
Commit message (Collapse)AuthorAgeFilesLines
* xargs: Convert tests to ATFDag-Erling Smørgrav2025-07-264-39/+194
| | | | | | | | Also add license and copyright statement, with permission from the original author. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D51537
* xargs: Limit -n to {ARG_MAX}Dag-Erling Smørgrav2025-07-263-5/+5
| | | | | | | | | | | | | | Since it's not possible to pass more than {ARG_MAX} bytes on the command line, it's also not possible to pass more than {ARG_MAX} individual arguments. Therefore, {ARG_MAX} is a reasonable upper bound for the -n option. This resolves both the arithmetic overflow issue and the CI OOM issue, so we can safely re-enable the test. Fixes: eab91d008165 Fixes: 2682a1552724 MFC after: 1 week Reviewed by: jlduran, emaste Differential Revision: https://reviews.freebsd.org/D51536
* Remove residual blank line at start of MakefileWarner Losh2024-07-151-1/+0
| | | | | | | This is a residual of the $FreeBSD$ removal. MFC After: 3 days (though I'll just run the command on the branches) Sponsored by: Netflix
* Remove $FreeBSD$: one-line sh patternWarner Losh2023-08-164-4/+0
| | | | Remove /^\s*#[#!]?\s*\$FreeBSD\$.*$\n/
* xargs tests: Disable the test added in commit eab91d008165Mark Johnston2023-07-311-2/+4
| | | | | | This test has been triggering OOM kills in CI runs since it triggers an allocation of 16GB. Temporarily disable the test until the problem is solved one way or another.
* xargs: Install missing test output.Jose Luis Duran2023-07-132-1/+2
| | | | | | | Fixes: eab91d008165e7bbf8ca7b87eabe4dc8bf3da191 MFC after: 1 week Reviewed by: des Differential Revision: https://reviews.freebsd.org/D41033
* xargs: Fix test case count.Dag-Erling Smørgrav2023-07-131-1/+1
| | | | | MFC after: 1 week Sponsored by: Klara, Inc.
* xargs: Prevent overflow in linelen calculation if nargs is large.Dag-Erling Smørgrav2023-07-132-0/+2
| | | | | | | MFC after: 1 week Sponsored by: Klara, Inc. Reviewed by: kevans Differential Revision: https://reviews.freebsd.org/D41023
* xargs: fix -R so that it accepts negative numbers againDaniel Tameling2023-07-133-1/+7
| | | | | | | | | | | | | fbc445addf9 converted the parsing of arguments to strtonum but made the accepted range for -R too restrictive. As documented in the man page, it should accept negative numbers. Added a test for this, which was provided by Jose Luis Duran. Fixes: fbc445addf9 MFC after: 1 week Reviewed by: des, kevans Differential Revision: https://reviews.freebsd.org/D41021
* xargs: fix exit code when using -Pliu-du2022-10-171-1/+6
| | | | | | | | | currently when xargs runs in parallel mode (e.g. -P2), it somtimes incorrectly returns zero exit code. this commit fix it and also adds tests. Reviewed by: mjg PR: 267110
* Merge ^/user/ngie/release-pkg-fix-tests to unbreak how test files are installedEnji Cooper2016-05-041-23/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | after r298107 Summary of changes: - Replace all instances of FILES/TESTS with ${PACKAGE}FILES. This ensures that namespacing is kept with FILES appropriately, and that this shouldn't need to be repeated if the namespace changes -- only the definition of PACKAGE needs to be changed - Allow PACKAGE to be overridden by callers instead of forcing it to always be `tests`. In the event we get to the point where things can be split up enough in the base system, it would make more sense to group the tests with the blocks they're a part of, e.g. byacc with byacc-tests, etc - Remove PACKAGE definitions where possible, i.e. where FILES wasn't used previously. - Remove unnecessary TESTSPACKAGE definitions; this has been elided into bsd.tests.mk - Remove unnecessary BINDIRs used previously with ${PACKAGE}FILES; ${PACKAGE}FILESDIR is now automatically defined in bsd.test.mk. - Fix installation of files under data/ subdirectories in lib/libc/tests/hash and lib/libc/tests/net/getaddrinfo - Remove unnecessary .include <bsd.own.mk>s (some opportunistic cleanup) Document the proposed changes in share/examples/tests/tests/... via examples so it's clear that ${PACKAGES}FILES is the suggested way forward in terms of replacing FILES. share/mk/bsd.README didn't seem like the appropriate method of communicating that info. MFC after: never probably X-MFC with: r298107 PR: 209114 Relnotes: yes Tested with: buildworld, installworld, checkworld; buildworld, packageworld Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=299094
* MFHGlen Barber2016-03-101-0/+11
|\ | | | | | | | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=296625
| * DIRDEPS_BUILD: Connect MK_TESTS.Bryan Drewery2016-03-091-0/+11
| | | | | | | | | | | | | | Sponsored by: EMC / Isilon Storage Division Notes: svn path=/head/; revision=296587
* | First pass to fix the 'tests' packages.Glen Barber2016-02-021-0/+4
|/ | | | | | | Sponsored by: The FreeBSD Foundation Notes: svn path=/projects/release-pkg/; revision=295171
* Refactor the test/ Makefiles after recent changes to bsd.test.mk (r289158) andEnji Cooper2015-10-121-2/+0
| | | | | | | | | | | | | | | netbsd-tests.test.mk (r289151) - Eliminate explicit OBJTOP/SRCTOP setting - Convert all ad hoc NetBSD test integration over to netbsd-tests.test.mk - Remove unnecessary TESTSDIR setting - Use SRCTOP where possible for clarity MFC after: 2 weeks Sponsored by: EMC / Isilon Storage Divison Notes: svn path=/head/; revision=289172
* Fix the racy xargs -P0 -n2 test added in r286289Enji Cooper2015-08-212-3/+3
| | | | | | | | | | | Sort the output obtained from xargs and the expected output to ensure the end result versus the input file is stable Differential Revision: D3432 Submitted by: Nikolai Lifanov <lifanov@mail.lifanov.com> Notes: svn path=/head/; revision=287005
* Disable the -P0 testEnji Cooper2015-08-211-1/+1
| | | | | | | | | It's unreliable (sometimes it passes, sometimes it fails) Reported by: Jenkins (many times over the past few weeks) Notes: svn path=/head/; revision=287004
* fix regression in xargs -Px (introduced in r286289) and add regression testsAllan Jude2015-08-085-1/+16
| | | | | | | | | | | PR: 202152 Submitted by: jbeich (original), Nikolai Lifanov (final) Reviewed by: jbeich Approved by: bapt (mentor) Differential Revision: https://reviews.freebsd.org/D3330 Notes: svn path=/head/; revision=286461
* Migrate most of tools/regression/usr.bin/ to the new tests layout.Julio Merino2014-03-1619-0/+131
I'm starting with the easy cases. The leftovers need to be looked at a bit more closely. Note that this change _does_ modify the code of the old tests. This is required in order to allow the code to locate the data files in the source directory instead of the current directory, because Kyua automatically changes the latter to a temporary directory. Also note that at least one test is known to be broken here. Actually, the test is not really broken: it's marked as a TODO but unfortunately Kyua's TAP parser currently does not understand that. Will have to be fixed separately. Notes: svn path=/head/; revision=263227