Commit graph

1019 commits

Author SHA1 Message Date
Robert Watson f4997daeac Add simple TCP connect and TCP receive benchmark components, intended to
measure the rate of TCP connection round trips supported by a host at
the socket layer.
2005-10-05 12:10:35 +00:00
Brooks Davis 97fb6f6f5d Add regression tests for trimdomain(3). 2005-10-05 04:46:10 +00:00
Max Khon 1d12d2a87f Use mkuzip(8) instead of create_compressed_fs. 2005-09-29 22:41:20 +00:00
Poul-Henning Kamp 8ec7a2f521 Fix a bug in disk geometry calculation.
Fix NANO_TOOLS usage in FlashDevice()
2005-09-29 16:06:59 +00:00
Poul-Henning Kamp 5dd35f9e69 This one goes as well. 2005-09-26 14:58:58 +00:00
Poul-Henning Kamp bce8140d46 Remove the old Makefile based nanobsd build method, the new shell script
based is far better and the only one supported from now on.
2005-09-26 14:57:27 +00:00
Poul-Henning Kamp 006ffd3415 Correct filesystem mountpoint 2005-09-25 21:23:19 +00:00
Simon L. B. Nielsen 06578727e1 Make it possible to set the NANO_TOOLS variable to a directory outside
of $NANO_SRC, which can e.g. be used if the nanobsd scripts are not in
the source tree being built.

Improved by:	phk
Approved by:	phk
2005-09-24 12:26:59 +00:00
Philip Paeps eb9323503c Fix typo. MAILWRAPER -> MAILWRAPPER.
Spotted by:	Andrea Campi <andrea+freebsd_cvs_all -at- webcom.it>
Pointy hat to:	philip
2005-09-21 12:32:06 +00:00
Poul-Henning Kamp a9793e1d67 Update these scripts to be more userfriendly and usage safe. 2005-09-21 09:40:45 +00:00
Poul-Henning Kamp 26b9c7716a Add a convenience function to set NANO_MEDIASIZE, NANO_HEADS and NANO_SECTS
for commonly used flash devices by

	FlashDevice Sandisk 256MB

in the config file.
2005-09-20 09:07:18 +00:00
Poul-Henning Kamp dbd5c1cfe5 Create an /etc/nanobsd.conf in the built image and put the disk drive name
there for scripts to use.

Create a noauto fstab entry for the configuration partition (/cfg).

Add NANO_TOOLS env-var to point to the nanobsd sources relative to
NANO_SRC.

Add -h argument which prints a usage.

Add -b argument which skips build steps and goes directly to install steps.

Complain about extraneous arguments, it's usually a forgotten '-c'

Add convenience function to register customization function.

Add some sample customization functions:
	cust_comconsole
	cust_allow_ssh_root

Rename setup_diskless() to setup_nanobsd(), it makes more sense.

Add various comments etc.
2005-09-20 08:38:59 +00:00
Poul-Henning Kamp cf61a39e6c Dump the environment for reference.
Add a function to add customization commands.
2005-09-19 20:55:44 +00:00
Robert Watson 5334bbba91 Small regression test tool to generate two forms of ENOSPC on a file
system: out of blocks, and out of inodes.  Useful for exercising the
uprintf(9) calls in UFS/ext2fs in order to detect races.
2005-09-19 16:29:36 +00:00
Poul-Henning Kamp c19b92e968 Create fstab before linking stuff into /conf 2005-09-19 15:41:08 +00:00
Poul-Henning Kamp db2dc2cd01 Missing ')' 2005-09-19 12:12:07 +00:00
Marcel Moolenaar b1fa310c00 o Extend the suite to run more than just the driver. We need to run
mdconfig(8), because we need a disk to work on.
o  Extend the number of tests now that we have a disk.
o  Simplify the driver. All parameters are ASCII strings now.
2005-09-19 06:51:57 +00:00
Marcel Moolenaar 6763e7c1ed Add the beginnings of a testsuite for testing GPT control requests.
The testsuite is based on a simple driver program that builds a
request from the arguments passed to it and issues the request to
Geom. The driver emits FAIL with the error string or PASS depending
on whether the request completed with an error or not. A -v option
has been added to the driver and causes the request to be dumped.
The -v option to prove(1) controls the -v option to the driver.

The testsuite itself contains a hash of which the key constitutes
the arguments and the value is the expected result.
2005-09-19 02:59:09 +00:00
Robert Watson d742e4abaf Add a regression test for listen()'s backlog argument, both at time of
creation and at time of update using an additional call to listen().
This test also exercises SO_LISTENQLIMIT, a forthcoming socket option
that allows the retrieval (but not setting) of the queue limit.

Discussed with:	andre
2005-09-18 13:42:19 +00:00
Christian S.J. Peron d1c48a07c3 Remove reference to bpfstat, this no longer exists. 2005-09-17 23:45:22 +00:00
Maxim Konovalov be875755ce Remove checks for shutdown(2) on non-connected socket. 2005-09-15 13:20:39 +00:00
Robert Watson 660f25118c Add two small tests to set and clear two file I/O flags using ioctl on
a fifo: FIONBIO, FIOASYNC.
2005-09-13 17:25:35 +00:00
Robert Watson 1c3c40d4c0 Restructure fifo_io event-related tests in order to support test cases
relating to O_RDWR file descriptors, which while not defined in POSIX,
are in fact used:

(1) Revise assumption that we have two file descriptors when testing I/O
    operations on a fifo.  Provide cleanup routines that handle either
    two or three file descriptors (including a kqueue descriptor).

(2) Add an openfifo_rw() routine to supplement openfifo().

(3) kqueue_setup() now configures an existing kqueue to monitor a new
    file descriptor, rather than allocating a new kqueue to monitor two
    existing file descriptors.

(4) Wrap all direct poll/select/kqueue/FIONREAD interactions in a single
    function, assert_status(), which takes a file descriptor, kqueue
    descriptor, assertion of read/writable/exception states, and
    test description, then tests the assertion.  This reduces the bulk
    of calls in many of the tests, making them shorter, more readable,
    and easier to determine correct.

(5) Add a new test_events_rdwr() function, which performs a basic create/
    write/read event test on a O_RDWR fifo file descriptor.  This is
    currently failed by our fifo code in HEAD due to a bug in FIONREAD
    handling.  Fix to be merged shortly.
2005-09-13 17:15:05 +00:00
Christian S.J. Peron 544b9dfe25 Garbage collect bpfstat. This is handled by netstat now.
Requested by:	rwatson
2005-09-13 16:04:56 +00:00
Robert Watson f8f8772ade Teach fifo_io how to use ioctl(FIONREAD) to determine if a fifo is
readable, and use that in addition to poll+select+kqueue to verify
appropriate readability.
2005-09-13 15:49:12 +00:00
Robert Watson 51c1fa5c31 Remove a debugging printf. 2005-09-13 10:33:32 +00:00
Robert Watson 456068c703 Comment test_lseek().
Add test_kqueue(), which registers and unregisters various kqueue filter
types on a fifo in order to make sure that EVFILT_READ, EVFILT_WRITE can
be registered, and that EVFILT_NETDEV can't be registered.  For now, we
don't test that EVFILT_VNODE can be registered on fifos, as that has been
broken at some point.
2005-09-12 19:31:16 +00:00
Robert Watson 1423f2f54c Further updates to fifo_io regression test:
- Teach fifo_io about kqueue monitoring of fifo file descriptor status,
  and add test cases for kqueue to match existing case for poll and
  select.  Add a new cleanup routine, cleanfifokq(), for use in tests that
  use kqueues.  kqueue_setup() sets up kqueue sessions, and kqueue_status()
  returns file descriptor status.

- Correct a bug in select handling relating to the nfds argument, which
  was incorrect so resulted in select occuring on the wrong file descriptor,
  and possible false positive/negative results.

- Clarify error reporting in one byte write+read tests to distinguish
  errors in the after case from the before case.
2005-09-12 17:05:48 +00:00
Maxim Konovalov bf6a2064bc o Add shutdown(2) regression tests. At the moment we cannot pass
shutdown-on-non connected socket test, kern/84761.
2005-09-12 14:12:09 +00:00
Robert Watson 062defcd30 Add fifo_misc, a regression test to hold misc. functional tests for fifos
that don't obviously fit into create, open, and io.  For now, add only a
regression test to make sure that lseek() fails with ESPIPE (which it
doesn't).
2005-09-12 11:58:14 +00:00
Robert Watson 76fe467ae4 Use different temporary directory templates for fifo_io and fifo_open so
that if the tests fail to GC their working spaces, it's clear which it is.
2005-09-12 11:43:51 +00:00
Robert Watson baabf9536d Add fifo_io, a regression test for I/O operations on POSIX fifos. We
currently can't pass this regression test due to broken poll() and
select() support for fifos, but past the basic I/O operation tests.
2005-09-12 09:42:29 +00:00
Robert Watson 544cf87d83 After going to some trouble to create a temporary directory in which to run
fifo tests, chdir to it.
2005-09-11 17:41:32 +00:00
Robert Watson 9c40729fdf Add fifo_open, a basic regression test for opening fifos, which tests
the blocking and non-blocking forms of open based on the POSIX spec for
now O_NONBLOCK should be handled.
2005-09-11 13:03:36 +00:00
Robert Watson c6c7bd16ce Add fifo_create, a simple regression test for mkfifo(2). 2005-09-10 21:09:26 +00:00
Christian S.J. Peron fa973e67a4 Now that the PID is constantly refreshed, introduce a pidname function which
when given a PID consults the kern.proc.pid sysctl variable to pull out the
pcomm data.
2005-09-05 23:13:05 +00:00
Robert Watson e9cc9cec0c Add a regression test to test two variations on the same bug: joining a
multicast group using a raw socket, then removing the interface on which
the group is found, and joining a multicast group using a udp socket,
then removing the interface on which the group is found.  An if_disc
interface is used as the interface on which to attach.

NB: A panic currently results from running this regression test, so do
so with caution.

PR:		77665
Reported by:	Gavin Atkinson <gavin dot atkinson at ury dot york dot ac dot uk>
Reported by:	Brooks Davis <brooks at FreeBSD dot org>
2005-09-05 13:23:01 +00:00
Stefan Farfeleder e594c724ee - Add tests for hash and return and more tests for set -e.
- Simplify regress.sh, sort tests.
2005-09-05 09:42:10 +00:00
Stefan Farfeleder 7784798d1b Simplify and add PR 77067 which addresses the same bug. 2005-09-04 21:29:09 +00:00
Stefan Farfeleder e4562fb6e8 Fix syntax error that crept in somehow. 2005-09-04 18:12:21 +00:00
Stefan Farfeleder afb2e8b616 Add a couple of regression tests for /bin/sh. 2005-09-04 11:59:59 +00:00
Sam Leffler f3ba19c9f3 script to set ifs parameters based on distance; derived from program
of the same name by Gunter Burchardt

MFC after:	3 days
2005-08-30 16:03:15 +00:00
Maxim Sobolev db45c56d7d Extend utility to allow recovering single file from the deffective
media.

MFC after:      2 weeks
2005-08-29 23:08:01 +00:00
Simon L. B. Nielsen 9e982c116f Correct a comment to match the configuration parameter it describes.
MFC after:	3 days
2005-08-27 20:57:06 +00:00
Pawel Jakub Dawidek b94557c2aa Add regression tests for '-L' option. 2005-08-25 20:13:58 +00:00
Pawel Jakub Dawidek 02a76f3fd7 '-F' option behaviour was reverted, so revert previous commit. 2005-08-25 20:11:39 +00:00
Pawel Jakub Dawidek dfe47d36df '-F' option now needs locked pidfile. Modify regression tests respectively. 2005-08-24 19:39:29 +00:00
Christian S.J. Peron ae21aee6ff Add support for processing the "bd_locked" flag offered by the bpf
stats structure.
2005-08-23 00:06:04 +00:00
Poul-Henning Kamp f763f86b1d Increase flexibility in disk-layout 2005-08-16 05:49:17 +00:00
Poul-Henning Kamp 034d67974c Put more stuff in logfiles instead of stdout 2005-08-15 18:40:28 +00:00
Poul-Henning Kamp a0f08bdf0c Cleanup and polishing. 2005-08-15 12:48:42 +00:00
Poul-Henning Kamp 27fa5ded62 After much experimentation, settle for the simplest model for customize
scripts.
2005-08-15 08:13:01 +00:00
Poul-Henning Kamp 202cd57290 Prune empty directories in /usr
Move argv parsing.
2005-08-13 08:06:18 +00:00
Poul-Henning Kamp 22aec2a315 Update to latest version of this tool.
Takes about a week for a full run.
2005-08-09 09:27:11 +00:00
Sam Leffler 6ae4f72691 sigh, sizeof the correct variable so we can match ifname's > 4 bytes 2005-08-06 18:47:12 +00:00
Robert Watson fa2b8debfe Add a few more system call timing cases:
Rename current socket creation test to socket_stream.
Add new socket_dgram test.
Add new socketpair_stream test.
Add new socketpair_dgram test.
2005-08-03 17:33:46 +00:00
Sam Leffler f0abdaaa64 simplify use with non-ath devices; search the wlan sysctl nodes to
locate the right one for the specified interface

MFC after:	3 days
2005-08-03 04:25:04 +00:00
Poul-Henning Kamp 511dca89b7 polish various bits. 2005-08-02 20:09:45 +00:00
Poul-Henning Kamp d9f9156b84 Ignore CVS directories 2005-08-02 20:09:24 +00:00
Poul-Henning Kamp 7abfae504a typo 2005-08-01 08:24:03 +00:00
Poul-Henning Kamp c14037d0a2 Add stuff to HTML output. 2005-07-31 15:42:25 +00:00
Poul-Henning Kamp 68d71fe787 The beginnings of a tool to survey the build options (NO_THIS, NO_THAT etc)
for effect.
2005-07-31 14:16:13 +00:00
Dag-Erling Smørgrav 8b4c82b30e In realpath(), make sure each path component consists only of safe
characters, and untaint it.
2005-07-29 11:28:03 +00:00
Dag-Erling Smørgrav 614232077b Differentiate between empty and short reports, and raise the bar for what
we consider a short report to 128 characters.  Canonicalize %%HOME%%.
2005-07-29 11:25:10 +00:00
Dag-Erling Smørgrav 9c89ce0f27 Don't email reports that are empty or very short, as can happen if tbmaster
fails to exec the tinderbox script.
2005-07-29 11:18:35 +00:00
Dag-Erling Smørgrav e873b4d1bc Shorten src / obj paths while capturing logs, making them both smaller and
easier to read.
2005-07-28 10:09:22 +00:00
Pawel Jakub Dawidek 229e613662 Add regression tests (121 in total) for GEOM_ELI class.
To use them, run:

	# prove /usr/src/tools/regression/geom_eli

Sponsored by:	Wheel Sp. z o.o.
		http://www.wheel.pl
MFC after:	1 week
2005-07-27 22:27:30 +00:00
Christian S.J. Peron 914aa01ca3 Add a description for bpfstat 2005-07-26 21:44:40 +00:00
Christian S.J. Peron c0b73d79e5 Introduce a bpfstat utility. This program can be used to retrieve
stats provided by bpf(4). This program will live in tools/ for now
until we figure out where it will live permanently. Based on some
discussions on developers@, it is likely that we will be adding
this functionality to netstat(1) at some point.
2005-07-26 21:38:54 +00:00
Poul-Henning Kamp 2a6de17fc9 Add the first snapshot at rewriting the nanobsd build to be a shellscript.
The overall idea is to get a single build script which will not need
editing, but instead overrides and changes happen by config files passed
as arguments.
2005-07-26 18:52:50 +00:00
Philip Paeps fc2d060bf7 Add some more NO_FOO options. I'm not sure if they're correctly sorted in the
size-scheme.  Also add commented NO_BIND_FOO options for people who want named
but not all of the bloat it likes to include by default.

While here, make a comment about BOOT_COMCONSOLE_SPEED.
2005-07-25 09:15:12 +00:00
Philip Paeps 1d22933171 Add fstab entries for ALTROOTSLICE and CFGSLICE, allowing us to do away with
most of the hardcoding of device names in installed convenience scripts.

Provide a new script (root/updatep) to easily update the ALTROOTSLICE.  It
does the same as updatep1/updatep2 without hardcoded device names.  If noone
protests, I'd like to get rid of updatep1/updatep2 at some point.

As an extra bonus: turn on the error led while updating (on hardware with a
led).
2005-07-25 08:40:13 +00:00
Pawel Jakub Dawidek 3c0a99e66e Change jail IP from 1.0.0.127 to 127.0.0.1, which shows, that this test
doesn't examine the real issue as it pass without problems.
2005-07-23 05:40:17 +00:00
Sam Leffler 1686ab4639 update for recent additions 2005-07-22 23:37:03 +00:00
Sam Leffler 0b42c00c0e update with new msg classes 2005-07-22 23:33:33 +00:00
Robert Watson b7b85f242e Add a simple multicast socket regression test set:
- Test that the basic socket options have the right defaults, that we can
  change them, read them back, etc.

- Add and remove some multicast addresses.

- Send a loopback multicast address and make sure it arrives intact.

There's more that could be done here, but it's a start.

MFC after:	3 days
2005-07-22 19:36:29 +00:00
Poul-Henning Kamp 4a7f3dcea5 In 2003, a -s flag was added to ministat to separate the
avg/median/stddev bars onto separate lines for readability if the
ranges overlapped.  In 2005, ministat was extended to support more than
2 datasets, but the -s code was not updated.  It will coredump if run
with -s and >2 sets.

PR:	82909
Submitted by:	Dan Nelson <dnelson@allantgroup.com>
2005-07-21 08:32:56 +00:00
Dag-Erling Smørgrav dc8d555647 Catch up. 2005-07-20 20:01:37 +00:00
Dag-Erling Smørgrav 747e5e832f Remove redundant rc files. 2005-07-20 20:00:51 +00:00
Dag-Erling Smørgrav a3264f50a1 CURRENT -> HEAD, and dump ia64 and powerpc. 2005-07-20 19:59:46 +00:00
Dag-Erling Smørgrav d40cc34afc Use 'HEAD' instead of 'CURRENT', while retaining backward compatibility. 2005-07-20 19:58:47 +00:00
Dag-Erling Smørgrav 866f6f4dda Include RELENG_4_11 and RELENG_4. 2005-07-20 19:51:13 +00:00
Dag-Erling Smørgrav 811f4dda90 Include RELENG_5_4 and RELENG_5. Chuck out ia64. 2005-07-20 19:50:29 +00:00
Dag-Erling Smørgrav aa17454eed Add rc files for RELENG_6. 2005-07-20 19:49:36 +00:00
R. Imura 1404c3a4b8 Add another regression tests for msdosfs which covers msdosfs_conv.c rev 1.45.
Requested by:	silby
2005-07-18 12:15:24 +00:00
Garance A Drosehn e9651b673d Correct one regression test (which was expected an incorrect answer), and
add a few more tests.  This matches bug fixes recently committed to 'env'.
2005-07-15 02:31:15 +00:00
Philip Paeps 205ede2568 Fix a minor buglet making the code match the comment. Fractional cylinders
confuse fdisk and break the NanoBSD build.

This is an MT5/6 candidate.

MFC after:	3 days
2005-07-14 12:20:02 +00:00
Garance A Drosehn 2c87a19e7a Upgrade these regression tests to track recent changes to `env'.
Approved by:	re (blanket `env')
2005-06-21 21:43:38 +00:00
Garance A Drosehn 6cc00fe24c Add a suite of regression tests for all the recent changes to `env',
using my own script to handle it.  I wrote my own partially because
of all the quoting-issues involved with testing what I wanted to test,
and partially because this lets me commit one script and one data file,
instead of one-file-per-regression-test.

This suite was good enough for my initial testing (and it did help me
find a few bugs that would have otherwise been missed).  I'm not sure
how well it will work in general use, but I figured I might as well
commit it.  It won't *hurt* to have it available.  At the worst, people
can just ignore it.

Approved by:	re (blanket `env')
2005-06-20 04:17:12 +00:00
Maxim Konovalov 922a5d9c2b o setsockopt(2) cannot remove accept filter. [1]
o getsockopt(SO_ACCEPTFILTER) always returns success on listen socket
  even we didn't install accept filter on the socket.
o Fix these bugs and add regression tests for them.

Submitted by:	Igor Sysoev [1]
Reviewed by:	alfred
MFC after:	2 weeks
2005-06-11 11:59:48 +00:00
Maxim Sobolev a09b2401cd Add entry for recoverdisk. 2005-06-06 00:18:17 +00:00
Hartmut Brandt 5878452aa9 Add a test for escaped newline handling. 2005-06-01 11:26:47 +00:00
Hartmut Brandt 6772dd14cb Add support for TODO tests. These are tests that are supposed to fail,
because of a make bug that should be fixed.
2005-06-01 11:25:38 +00:00
Hartmut Brandt d9ea463fbf Change the test infrastructure so that tests are easier to maintain and
so that make(1) will run in an almost clean environment and enhance the
description of the test infrastructure.

Add the ability to have multiple tests carried out per test script.

Give some tests more meaningful names.

Fix the usage message from the test scripts.

Make it possible to pass several commands to the test scripts like:
'sh test.t setup run compare clean'.
2005-05-31 14:13:07 +00:00
Robert Watson cd05b0f7a1 dd a '-n' option to ministat, which causes it to display only summary
statistics, not graph and statistical test output.  Useful for automated
processing.
2005-05-27 17:52:56 +00:00
Hartmut Brandt cfc967e66a Add a test to check whether in compat mode make detectes builtins
on the command line and really executes the shell instead of directly
executing the command.
2005-05-20 15:25:04 +00:00
Hartmut Brandt ac8946e3d3 Add a test to ensure that in compat mode when a line contains no
shell meta characters it is not passed to the shell, but the command
is executed directly (given that the line is not a shell builtin) and
that the line with a meta character is passed to the shell.
2005-05-20 15:06:27 +00:00
Hartmut Brandt c9302692e6 Add a test that test whether we can replace the shell to use by
make with another shell and set all its parameters (meta and builtins
not tested here).
2005-05-20 14:50:30 +00:00
Poul-Henning Kamp 0f93d8245d Make the path to make.conf a parameter which can be overridden.
NB: you have to use absolute path!
2005-05-19 15:34:36 +00:00
Poul-Henning Kamp af7b2a826c Save space by using -b 4096 -f 512 for newfs.
Retain -i 8192 to avoid wasting inodes.
2005-05-19 15:34:00 +00:00