Commit Graph

515 Commits

Author SHA1 Message Date
rwatson
85222c8750 Add a short regression test that triggers a TCP socket to enter time wait
while the socket is still open; one variant closes the socket while in
time wait, and a second lets time wait expire while the socket is open.
2006-04-02 00:07:38 +00:00
rwatson
ddc54b9056 Add spxabort, a simple netipx/spx regression test that triggers
pru_abort() by closing a listen socket while completed connections are
presenting in its listen queue.  Unfortunately, it's difficult to
trigger the other two pru_abort() cases using user APIs, so they are
not covered by this test.
2006-03-27 00:03:37 +00:00
rwatson
6e86a80ea8 Add simple regression test to ping pong a data packet over SPX in stream
mode.  Support both connection via connect() and sendto(), but don't
compile in sendto() for now, since netipx doesn't appear to actually
implement that (doh).
2006-03-26 19:10:27 +00:00
rwatson
5d9ced7701 Add a simple IPX datagram regression test, which opens two IPX datagram
sockets, binds a local port, sends a datagram, and confirms that it is
received.
2006-03-26 18:25:53 +00:00
rwatson
deeedd413a Add a short README with configuration hints to get the netipx regression
tests up and running.  This is likely a message to myself in six months
when I've completely forgotten how.
2006-03-26 17:42:04 +00:00
rwatson
73eedc13f0 Modify ipxsocket regression test to create and close sockets several
times, with variable length sleeps between socket() and close().  This
will help to ensure that IPX/SPX timers fire while the sockets are
open, and hence have PCB's on the IPX pcb list, so that if timers are
going to stumble over PCB types they don't expect, it will happen as
part of this test.
2006-03-26 15:49:35 +00:00
rwatson
72eb76f920 Add simple ipxsocket regression test: open, and close, various IPX socket
types supported by the FreeBSD netipx implementation.
2006-03-26 01:58:39 +00:00
rwatson
65c4a2a9dc Merge Perforce change 93572 from TrustedBSD audit3 branch:
Simple audit pipe ioctl regression test.

Obtained from:	TrustedBSD Project
2006-03-19 15:47:53 +00:00
rwatson
cbcf9b2ad9 Change s_net to s_node when printing the destination address. 2006-03-17 20:14:25 +00:00
ru
38ea5a1166 NO_MAN is not needed here. 2006-03-16 15:18:17 +00:00
ru
30cc3ea988 Style: NO_MAN doesn't need any value. 2006-03-15 10:46:38 +00:00
ume
940db6a9cd NOMAN --> NO_MAN 2006-03-07 14:26:17 +00:00
pjd
24e4deddbc Add regression test which verifies that options -P and -i cannot be used
together.

MFC after:	3 days
2006-02-12 02:07:56 +00:00
pjd
41ffd5b92b Add regression tests which will verify that giving no key components for
init/attach/setkey subcommands is really impossible.

MFC after:	3 days
2006-02-01 15:17:45 +00:00
pjd
9cd2981517 Add simple tests which verify that redzone(9) works properly. 2006-01-31 11:20:13 +00:00
davidxu
af24439a4a s/sigval/sival/g 2006-01-22 03:46:03 +00:00
avatar
e9ab99b720 Adding another multi-byte characters related regression test for recent
nmount(2) adoption.
2006-01-01 01:28:31 +00:00
pjd
4ed0dcf09f Convert gstripe(8) regression tests to the new framework. 2005-12-07 01:30:44 +00:00
pjd
5250c7022c Convert gshsec(8) regression tests to the new framework. 2005-12-07 01:29:50 +00:00
pjd
ef0831aea7 Convert graid3(8) regression tests to the new framework. 2005-12-07 01:28:59 +00:00
pjd
970cb6f33a - Make use of geom_subr.sh to improve regression tests.
- Keep class-specific data in conf.sh file.
2005-12-07 01:27:23 +00:00
pjd
65dce3ed0a Finish conversion of gconcat(8) regression tests to the new framework. 2005-12-07 01:24:25 +00:00
pjd
49984acede Add file with helper functions for geom tools regression tests. 2005-12-07 01:20:18 +00:00
pjd
878b30658c Convert gnop(8) regression tests to the new framework. 2005-12-07 00:37:14 +00:00
pjd
9795800eb3 Convert gmirror(8) regression tests to the new framework. 2005-12-07 00:34:27 +00:00
davidxu
b2bbf4f8ad Add code to test POSIX message queue. 2005-11-26 13:19:09 +00:00
marcel
7e399ad83e Update to match geom_gpt:1.35
o  Change the result of gctl(001) now that a bogus verb still requires
   a valid geom,
o  Insert gctl(024) to test for an appropriate error when a bogus verb
   is given that does have a proper geom parameter.
2005-11-13 22:02:04 +00:00
marcel
9ea593a1fb Instead of saving the unit number of the md(4) device name, save the
whole name. This does not unnecessarily close the door that in some
future we want to test on something other than md(4) devices.

Also add a "conf" action so that we can check whether a gctl actually
did the right thing or not. It's one thing to check that the result
strings are as expected, but it doesn't tell us if the end result is
correct. This needs a bit more fleshing out, but for now a visual
(i.e. manual) check suffices.
2005-11-12 20:17:08 +00:00
rwatson
c87b604005 Add unix_passfd, a simple set of regression tests for UNIX domain socket
file descriptor passing.  These tests are not all currently passed.
2005-11-09 21:41:20 +00:00
davidxu
622bb31c9a Add code to test queued SIGCHLD. 2005-11-08 09:19:44 +00:00
pjd
2d70eabb28 Add tests for -t option with short tty name - pkill(1) should accept both
(eg. "ttyv0" and "v0").
2005-11-07 16:56:16 +00:00
davidxu
18fc4b11b9 Add sigqueue test code. 2005-11-07 14:10:33 +00:00
stefanf
8723c51d6b Add test cases for the command built-in, including its -v and -V options which
I'll commit real soon.

Count the number of found test cases instead of hard-coding them.  Allow an
arbitrary exit status.
2005-10-28 14:02:42 +00:00
harti
d0b8720651 Add first tests for semicolon handling. The first test fails. This is
probably a bug in the parser.
2005-10-18 07:28:09 +00:00
harti
2733c20457 Add more tests for escaped newline handling and fix a test that currently
should fail because of a bug in the parser (test 2).
2005-10-18 07:20:14 +00:00
ambrisko
a7fa49849e This test can run now. 2005-10-12 18:04:18 +00:00
marcel
6c3e0035da Rough implementation of the create and add verbs. The verbs cause
in-memory changes only and as such are only useful for prototyping
and regression testing purposes.
2005-10-09 17:10:35 +00:00
brooks
0f2fe8b63d Add regression tests for trimdomain(3). 2005-10-05 04:46:10 +00:00
fjoe
5c713a5737 Use mkuzip(8) instead of create_compressed_fs. 2005-09-29 22:41:20 +00:00
rwatson
aaf789e510 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
marcel
d94a6a6215 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
37a0bbb7e5 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
rwatson
585452751e 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
maxim
a2d0692652 Remove checks for shutdown(2) on non-connected socket. 2005-09-15 13:20:39 +00:00
rwatson
a37e69ab0c 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
rwatson
5d506fa38f 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
rwatson
d843436403 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
rwatson
5dc127c9e2 Remove a debugging printf. 2005-09-13 10:33:32 +00:00
rwatson
3e75d8f4fd 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
rwatson
1149df53b0 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
6732fe0718 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
rwatson
bc20141649 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
rwatson
4bf620706a 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
rwatson
073fb90c59 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
rwatson
42860f374b 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
rwatson
529f801256 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
rwatson
03ae4bec97 Add fifo_create, a simple regression test for mkfifo(2). 2005-09-10 21:09:26 +00:00
rwatson
61c98b99f2 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
stefanf
560cfe4de3 - 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
stefanf
4a2e133e0f Simplify and add PR 77067 which addresses the same bug. 2005-09-04 21:29:09 +00:00
stefanf
ea45d0596e Fix syntax error that crept in somehow. 2005-09-04 18:12:21 +00:00
stefanf
ce5d9c9b6d Add a couple of regression tests for /bin/sh. 2005-09-04 11:59:59 +00:00
pjd
77f75e8428 Add regression tests for '-L' option. 2005-08-25 20:13:58 +00:00
pjd
034dae7724 '-F' option behaviour was reverted, so revert previous commit. 2005-08-25 20:11:39 +00:00
pjd
2cdfac31a9 '-F' option now needs locked pidfile. Modify regression tests respectively. 2005-08-24 19:39:29 +00:00
pjd
3f2c6109db 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
pjd
4138f701c8 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
rwatson
c45e23d039 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
imura
11bed7ab9b 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
gad
dae3611171 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
gad
2628b26a5e Upgrade these regression tests to track recent changes to `env'.
Approved by:	re (blanket `env')
2005-06-21 21:43:38 +00:00
gad
cb0516417f 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
e5e29d142d 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
harti
54f37e8648 Add a test for escaped newline handling. 2005-06-01 11:26:47 +00:00
harti
10c793046d 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
harti
316b5bf776 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
harti
e533045bcd 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
harti
d35d2dfc6f 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
harti
e956f972da 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
harti
b2f252c7bc Some test cases for .SHELL target: builtin shell selection and
changing the path of a builtin shell.
2005-05-19 11:23:01 +00:00
rwatson
449a09d7f4 Add an #ifdef'd non-blocking version of the test.
Update copyright.
2005-05-16 00:54:47 +00:00
rwatson
b7aef0ed3c Close the connect socket as well as the listen socket on completion.
Update copyright.
2005-05-16 00:53:38 +00:00
marcel
208bfa4234 o -n option added.
o  -x option added.
2005-05-15 07:35:34 +00:00
avatar
5264ecc9eb Catching up with the latest crypto API changes in net80211.
Reviewed by:	sam
2005-05-05 13:16:30 +00:00
ume
9f4066d658 add simple test script. 2005-05-05 11:26:47 +00:00
ume
f0bd095e96 - add $FreeBSD$.
- enable -r option for regress target.
2005-05-04 19:40:30 +00:00
ume
c93d1b9f93 - add $FreeBSD$.
- do service lookup.
- add options to use gethostbyname(3) or getipnodebyname(3) instead
  of getaddrinfo(3).
- add option to do reverse lookup.
2005-05-04 12:02:10 +00:00
ume
8f2ac72729 This commit was generated by cvs2svn to compensate for changes in r145857,
which included commits to RCS files with non-trunk default branches.
2005-05-04 11:55:42 +00:00
ume
d7fda39756 import of parallel name resolution test.
Obtained from:	NetBSD
2005-05-04 11:55:42 +00:00
harti
602fdc5e5e Add an initial regression test suite for make(1).
Submitted by:	Max Okumoto <okumotu@ucsd.edu> (partly, initial version)
2005-04-28 13:20:48 +00:00
davidxu
6149b9f287 Adjust code to be more reliable. 2005-04-24 00:17:30 +00:00
davidxu
72410b5004 Add a program to test if tls data is clean. 2005-04-23 23:47:58 +00:00
avatar
8694c5f462 Adding another multi-byte characters related regression test for msdosfs.
Tested by:	njl
Reviewed by:	silby, bde, sam (mentor)
2005-04-18 13:06:43 +00:00
silby
80df10c1f4 Add another regression test - one we don't pass right now. 2005-04-17 00:56:38 +00:00
silby
80d723ba1b Have the regression test use a path in /tmp for a mount point
instead of a directory that only exists on my machine.
2005-04-17 00:40:27 +00:00
trhodes
7abff596b2 Those who are ungodlike should be returned an error. 2005-04-16 18:41:00 +00:00
rwatson
a5028ef44e Starting point for a regression test for mac_bsdextended(4)/libugidfw(3).
Currently only performs basic tests against the library string routines,
and queries less important kernel state.

Obtained from:	TrustedBSD Project
Sponsored by:	SPAWAR, SPARTA
MFC after:	3 days
2005-04-16 12:06:40 +00:00
stefanf
73d2098d76 Also test \0 in the format string. 2005-04-14 18:33:14 +00:00
stefanf
c7fefa410d Add a few regression tests for printf(1). 2005-04-13 20:08:17 +00:00
silby
d0b8d01316 A simple regression test for msdosfs. Not the best, but it would have caught
the recent trouble msdosfs had.
2005-04-08 07:21:07 +00:00
das
bd50b9aebd Add missing test-rem.t. 2005-04-02 12:50:28 +00:00
das
d00974ed11 A few simple regression tests for remainder(), remainderf(),
remquo(), and remquof().
2005-03-25 06:24:46 +00:00
pjd
a0488b0220 Add regression tests for pkill/pgrep.
MFC after:	3 days
2005-03-20 12:38:08 +00:00
das
b424be5faf - Replace fe[gs]etmask() with feenableexcept(), fedisableexcept(), and
fegetexcept().
- Add additional tests for the above.
- Output a separate success message for each of the 8 components of
  this set of tests.
2005-03-16 19:04:45 +00:00
rwatson
1fbc0d2e52 Check the return value of shutdown(). 2005-03-11 13:05:18 +00:00
rwatson
832b048264 Add sigpipe, a simple UNIX domain socket and TCP regression test that is
intended to verify that SIGPIPE is delivered to a process writing or
sending on a socket that has been shut down for write.  If available,
SO_NOSIGPIPE is also tested.

This regression test is currently passed by RELENG_4, but not by HEAD or
RELENG_5, due to a bug in the write() code for sockets.  SO_NOSIGPIPE is not
present in RELENG_4, however, so is not tested there.

Reported by:	Mikko Tyolajarvi <mbsd at pacbell dot net>
PR:		78478
2005-03-11 12:47:14 +00:00
das
e73c425f78 Test cases for nextafter{,f,l} and nexttoward{,f,l}. 2005-03-07 05:03:46 +00:00
harti
13d684fd15 Repo-copy tools/regression/usr.bin/make to tools/build/make_check
and adjust the path in the Makefile for the upgrade_checks target.
These checks are really feature upgrade checks that should be fast
and just find out whether we need to build a new make before
proceeding with other targets like buildworld. This makes the
place free for a real regression test suite in the old place.
2005-03-02 12:33:23 +00:00
ambrisko
76dfd3add8 This will not compile without:
http://www.ambrisko.com/doug/listio_kqueue/listio_kqueue.patch

Note: it is a good idea to run this against a physical drive to
exercise the physio fast path (ie. lio_kqueue /dev/<something safe>)
This will ensure op's counting per LIO request is correct.  It is
currently broken the above patch fixes it.

Sponsored by:   IronPort
2005-03-02 04:00:55 +00:00
ambrisko
fd8046ee06 Add an AIO & kqueue regression test. It is a good idea to run this
against a disk as the argument.  If you don't it will use a temp file.
The raw disk will use the kernel physio fast path method until the
max number of pending op's is reached then it will queue them.  File
system op's are always queued.  This is more important with LIO since
operation can get split across and accounting of op's is broken with LIO.

Note that this was broken when locking was added to kqueue (ie. 5.3)
My fix needs to be better integrated with FreeBSD.

Next is an LIO test and implementation.

Sponsored by:	IronPort
2005-03-02 03:32:01 +00:00
das
1f1be76759 - Split tests into three rough categories.
- Use fesetround() instead of fpsetround(), and add tests for
  various rounding modes.
- Test that all NaNs generated are quiet.

Some of these tests won't pass until problems in vendor sources
(gdtoa and gcc) are fixed and new versions imported, but I
want to get these changes into the tree before I accidentally
blow them away again.  :-(
2005-03-01 01:43:20 +00:00
das
8448d77935 - Split the printfloat test into 11 individually wrapped and packaged
tests.  (Buy 10, get one free!)  The separate categories were
  already there; they just weren't labeled.
- Use fesetround() instead of fpsetround(), since the former is
  standard and implemented on all supported architectures.  Add
  tests for each rounding mode.
- Add additional tests for subnormals.

Some of these tests won't pass until problems in vendor sources
(gdtoa and gcc) are fixed and new versions imported, but I
want to get these changes into the tree before I accidentally
blow them away.
2005-03-01 01:43:05 +00:00
rwatson
357323f47c Add a simple regression test for stream UNIX domain sockets and the
bind()/connect() system calls, which is intended to confirm that the
right successes and errors occur when rendezvousing via the file system
name space.
2005-02-20 22:21:53 +00:00
ru
768d0ef9bc Add to CFLAGS. 2005-02-12 18:09:20 +00:00
nik
e789f38245 Add to CFLAGS, rather than overriding it. Use LDFLAGS for the -L option,
and LDLIBS to specify -ltap.

Submitted by:	ru
2005-02-01 09:26:34 +00:00
nik
41b0884fdc Link against libtap (ports/devel/libtap). Replace the calls to assert()
with calls to libtap::ok1(), and make sure the correct number of tests is
planned for, and that the exit code is correct.
2005-02-01 01:53:35 +00:00
marcel
a52d6034c2 Wrap calls to memcpy(3) in a function called block_copy(). This way,
and as long as we're not compiling with IPA, gcc(1) won't optimize
the call away. The whole purpose of using memcpy(3) is to avoid
misaligned loads and stores when we need to read or write the value
in the unaligned memory location. But if gcc(1) optimizes the call
to memcpy(3) away, it will typically introduce misaligned loads and
stores. In this context that's not a good idea.
2005-01-28 02:58:32 +00:00
marcel
2fd1a0c45b Skip the register based postinc stores here and don't count them
in the number of tests. This way we avoid skipped tests for non-
existent memory access combinations. The number of tests dropped
from 60 to 48.
2005-01-27 23:15:58 +00:00
marcel
c8ad56a37f Make the local variables global so that the compiler cannot assume
too much about them. This prevents certain peephole optimizations
at -O that invalidate the tests.
2005-01-27 23:11:55 +00:00
marcel
8c11911620 Fix the unaligned store with post increment test: The misaligned pointer
stopped pointing to the value the moment we wrote it due to the post
increment. So, grab the value for comparison out of the data structure
directly.
2005-01-27 22:46:15 +00:00
marcel
bf144c55ea The unit test for unaligned loads/stores can be found under ../ia64. 2005-01-27 06:51:45 +00:00
marcel
4722d1539a Add tests for post increment. This bumps the number of tests up to
60. The postinc store tests currently fail (value mismatch). Hence
the score as of this commit is 48 out of 60. Either the kernel or
the tests need to be fixed.
2005-01-27 06:50:05 +00:00
rwatson
96960d4e34 Use WARNS?= instead of WARNS= in Makefiles so that global warning
settings can override local ones.

Pointed out by:	ru
2005-01-22 22:42:39 +00:00
silby
67f0a2039e Add two more pipe regression tests. Not yet hooked into the test framework. 2005-01-21 06:46:18 +00:00
rwatson
ea812ffcf7 In refactoring the test before committing, a pointer was passed instead
of a structure for the sockaddr_in.  Pass the pointer to connect()
instead of the pointer to the pointer.

Specify a port number to connect to.
2005-01-16 15:01:28 +00:00
rwatson
69eae68c08 Add udpconnectjail, a simple regression test to exercise an (as yet)
unfixed bug in the jail() implementation relating to using the connect()
system call on UDP sockets.

PR:	26506
2005-01-16 13:05:32 +00:00
sobomax
319257bc18 Add test which excersises problem with unability to change association of
already associated datagram unix domain socket by issuing connect() system
call.
2005-01-12 09:57:18 +00:00
das
e71d433311 Regression tests for [l]lrint[f]() and [l]lround[f](). 2005-01-11 23:13:36 +00:00
pjd
8d8363ee39 Introduce a new GEOM class - SHSEC. It provides sharing secret between
the given providers. Without even one of the configured components there
should be no way to get the secret.

Supported by:	WHEEL Sp. z o.o.
		http://www.wheel.pl
2005-01-11 18:06:44 +00:00
pjd
fb444128a4 Fix incorrect comment.
MFC after:	3 days
2005-01-11 14:11:14 +00:00
rwatson
aedc2f346a Add a simple regression test for mlock()/munlock() to make sure they
work on a single page as root, and fails on a single page as nobody.
Intended to help diagnose reports regarding insecure memory use with
gnupg.
2005-01-03 19:56:20 +00:00
marcel
90a64b80c5 Replace a mention of the ia64_unaligned directory with one of the
ia64 subdirectory. All ia64 specific regression tests live under
the ia64 directory.
2005-01-02 21:40:36 +00:00
marcel
5370f7380f Regression test for unaligned loads and stores for short, int, long,
float, double and long double types. No post-increment tests yet.
All tests are skipped if the debug.unaligned_test sysctl variable
cannot be set to 1.
2005-01-02 21:33:40 +00:00
pjd
085de6ea5e Wait a bit after creating device. 2004-12-21 19:03:10 +00:00
pjd
13636f516f When RAID3 device is configured in "verify" mode, synchronization of the
parity component is now force on creation.
Change regression test which check "verify" mode to work properly after
this change.
2004-12-21 18:48:59 +00:00
ru
cec60429bb Start the dreaded NOFOO -> NO_FOO conversion.
OK'ed by:	core
2004-12-21 08:47:35 +00:00
sam
b63f688d6c Loadable modules that run test vectors for net80211 crypto plugins. 2004-12-08 17:45:53 +00:00
harti
c90efa2b2f Fix builds with a read-only directory and a make upgrade. This is done
by forcing the creation of an object directory for the make regression
tests. Let make handle the tracking of the dependency and installation
of test_shell script.

Submitted by:	ru
2004-12-07 14:41:16 +00:00
rwatson
3522c0a675 Print a warning if running as !root for aio_md_test rather than failing
the test.  Privilege is required in order to allocate an md device.
2004-12-06 13:15:23 +00:00
rwatson
8bd5ca5854 Add a basic aio functionality regression test, which simply writes and
then reads from a fairly broad range of object types: regular file,
fifo, UNIX socketpair, pty, UNIX pipe, and an md device.  Not a deep
test of functionality, just a basic test that aio_write followed by
aio_read returns the correct data in a relatively timely manner.

Requested by:	phk
2004-12-06 12:56:38 +00:00
ru
0a293bea5c Make this work under debugging, e.g., "make -dl". 2004-12-06 08:51:30 +00:00
harti
b9b9fdbd3f Make the tests runnable on a read-only src. To do this you must make sure
that you create one of the object directories make knows (see make(1)).
This uses the -C flag, so add a test that checks that make actually accepts
-C. Also fix the test that selects csh via the .SHELL target to work for
tcsh users too.

This commit renames shell_test to shell_test.sh. There is no history
to preserve so go without a repo-copy.

Reviewed by:	ru
2004-12-02 17:00:58 +00:00
nik
a138ae34c4 The following code sets up two connected TCP sockets that send data to each
other until the window is closed. Then one of the sockets is closed, which
will generate a RST once the TCP at the other socket does a window probe.

All versions of FreeBSD prior to 11/26/2004 will ignore this RST into a 0
window, causing the connection (and application) to hang indefinitely.
On patched versions of FreeBSD (and other operating systems), the RST
will be accepted and the program will exit in a few seconds.

Submitted by:	Michiel Boland
Reviewed by:	silby
2004-12-01 12:12:12 +00:00
harti
c87a620e46 Chmod the shell testscript to be executable if it isn't already. According
to the CVS-Meisters x-mode just happens to work, but is not guaranteed to
do so. Try to be on the safe side.
2004-11-30 15:33:18 +00:00
harti
f4e37f6f60 Add some regression tests for the .SHELL target. I'm not sure that the
output of shell_2j is actually correct - it just tests what make currently
does. Make should switch on echoing for the second line, shouldn't it?
2004-11-25 10:03:29 +00:00
tjr
4e61a637dc Remove regression tests for the obsolete rune interface. 2004-11-21 03:21:22 +00:00
nik
3e959a33f9 Switch over to a different, more flexible test output protocol that's
understood by Perl's Test::Harness module and prove(1) commands.

Update README to describe the new protocol.  The work's broken down into
two main sets of changes.

First, update the existing test programs (shell scripts and C programs)
to produce output in the ok/not ok format, and to, where possible, also
produce a header describing the number of tests that are expected to be
run.

Second, provide the .t files that actually run the tests.  In some cases
these are copies of, or very similar too, scripts that already existed.
I've kept the old scripts around so that it's possible to verify that
behaviour under this new system (in terms of whether or not a test fails)
is identical to the behaviour under the old system.

Add a TODO file.
2004-11-11 19:47:55 +00:00
rwatson
2db191c4fe Add a small regression test that opens a TCP socket, listens on it,
performs a non-blocking connect from another socket, and then closes
the listen socket rather than accepting.  This is intended to
exercise the close path in which connections are aborted due to a
close on the listen socket while the connection is in the listen
queue.
2004-11-02 17:59:12 +00:00
ru
5db2b9d5b3 For variables that are only checked with defined(), don't provide
any fake value.
2004-10-24 15:33:08 +00:00
rwatson
8ad3de471d Use errx() instead of fprintf()/exit() for conciseness.
Suggested by:	ru (some time ago)
2004-10-23 22:18:37 +00:00
rwatson
e5417785bf Use errx() instead of perror()/exit() for conciseness.
Suggested by:	ru (some time ago)
2004-10-23 22:11:35 +00:00
ru
8cebff99b3 Add a regression test for the alternate shell specification. 2004-10-23 21:38:58 +00:00
ru
d399f4ecf4 Fixed a typo.
Submitted by:	Pawel Worach
2004-10-17 11:07:03 +00:00
keramida
2eb8bfd316 Add a regression test for floating-point output in the Greek locale.
See revision 1.3 of src/share/numericdef/el_GR.ISO8859-7.src

Reviewed by:	das (a while ago)
2004-10-13 22:32:12 +00:00
rwatson
bcc7e348ba Resort unprivileged uid with privileged socket after unprivileged uid
with privileged socket in test runs.

If running unprivileged and instructed to use unprivileged sockets,
don't try and use raw sockets.
2004-10-11 19:12:40 +00:00
rwatson
4040b36fa7 A number of improvements to the IP socket option API regression test:
- Consistently use err/errx/warnx throughout, rather than using perror()
  and exit().

- Teach the tests how to better manage (and therefore test) privilege:
  in particular, how to create sockes with root credentials but exercise
  the privileges with non-root credentials, etc.

- Teach the test suite to apply each of the non-IP_HDRINCL options across
  each of SOCK_DGRAM, SOCK_STREAM, and SOCK_RAW.
2004-10-11 19:03:53 +00:00
stefanf
d9abb42b26 Add regression tests for ilogb{,f,l}(). 2004-10-11 18:40:45 +00:00
rwatson
8e1f60d994 Add a simple exercise suite for IP-level socket options. The suite
atempts to read and write various IP-level socket options as root and
nobody, making sure the initial values are as expected, that they can
be changed to valid values and take effect, etc.  No attempt is made
to check for the correct implementation of side effects (such as
changes in packet headers) as yet.

The IP options section is currently broken but will be fixed shortly.

Not all multicast options are currently tested.
2004-10-11 16:09:45 +00:00
rwatson
e6a8dc9c17 Add a simple C-based TCP connection generator, which generates and
closes the specified number of TCP connections sequentially and
synchronously.  Useful for trying to trigger races in the accept
code.
2004-10-09 20:58:28 +00:00
rwatson
1991acc23e Modify accept_fd_leak regression test to generate "PASS" output, not
just "FAIL" output, in order to make it consistent with other tests in
the regression test tree.
2004-09-18 13:06:00 +00:00
rwatson
a18be84c1f Add a very basic README for tcpstream. 2004-09-13 16:53:40 +00:00
rwatson
ed6044d475 Add tcpstream, a simple TCP stream generator that uses a pseudo-random
sequence to detect data corruption visible to an application.
2004-09-13 03:17:22 +00:00
stefanf
6d0c938ba1 Add a regression test for <tgmath.h>. 2004-09-04 11:34:53 +00:00
ru
083ce78d85 Join the effort in simplifying this makefile. ;) 2004-09-03 06:18:52 +00:00
rwatson
621b91453c Pass O_NONBLOCK directly to fcntl() rather than the pointer to an int
holding the value O_NONBLOCK.  This worked previously because I was
lucky.
2004-09-02 21:41:57 +00:00
rwatson
b9685c935d Don't override the rule used to build a binary by providing our own
compiler line.
2004-09-02 21:37:50 +00:00
rwatson
a52ebd899d Make sure to properly initialize 'size' to sizeof(sin) before passing
it into accept().  Depending on the initial value in memory, it is
otherwise possible to get EINVAL.
2004-08-24 04:59:26 +00:00
rwatson
45da4deacb Add a basic kqueue + UNIX domain socket pair regression test to do some
elementary exercising of kqueues on datagram and stream sockets.  Note
that the datagram write kqueue case is left untested due to potentially
confusing behavior for the developer (me) that might require attention.
2004-08-24 04:02:41 +00:00
pjd
9602bb2cd9 Regression tests for 'verify reading' algorithm. 2004-08-22 16:26:09 +00:00
pjd
6ac179d92c Add regression test for the new "round-robin reading" feature. 2004-08-21 18:14:55 +00:00
dfr
597fea43c0 Remove some debug cruft from the Makefiles and make them ${.OBJDIR}
friendly.
2004-08-16 09:35:49 +00:00
pjd
b636607ce6 Add regression tests for GEOM_RAID3. 2004-08-16 09:09:23 +00:00
ru
cfe021dc2b Replaced COPTS by equivalent CFLAGS. 2004-08-13 14:21:49 +00:00
fjoe
520f0cfead Regen. 2004-08-13 09:56:22 +00:00
fjoe
4cdbb4e4ad Regression test for geom_uzip. 2004-08-13 09:53:52 +00:00
harti
d04c2b4f9d Add a regression test for the ATM call control stuff. 2004-08-13 09:27:21 +00:00
harti
883c945b5c Now that make more correctly handles variable assignments
in .MAKEFLAGS targets enable the regression test for this.
2004-08-12 19:14:10 +00:00
dds
145dad6e9d Per letter dated July 22, 1999 remove 3rd clause of Berkeley derived
software (original contributor).

Reviewed by:	imp
2004-08-09 15:29:41 +00:00
harti
f2baa8f5ba Back out something I'm working on that crept in with the last commit.
Spotted by: ru
2004-08-05 09:11:44 +00:00
harti
679c187578 Remove extra spaces. Remove double quotes around error messages -
they are not needed and will actually be printed.

Submitted by:	ru
2004-08-05 08:44:00 +00:00
dfr
8f4eb605aa This file is not suppose be be all one big comment :-(
Pointed out by: ssouhlal
2004-08-05 08:07:40 +00:00
harti
c6e3261d2f Add another test that checks for a working '+' command flag. 2004-08-05 07:24:06 +00:00
pjd
be8c86ce12 Add regression test for "prefer" balance algorithm in MIRROR class. 2004-08-04 12:18:42 +00:00
harti
310a4a288d Add a regression test for the passing of command line
variable assignments via the MAKEFLAGS environment variable.
2004-08-04 07:40:58 +00:00
rwatson
83a61f757e Add minimal socketpair() regression test to confirm that we can create
(and close) PF_UNIX socket pairs, and that we can't create PF_INET
socket pairs.  More tests to follow.
2004-08-04 03:46:35 +00:00
dfr
c5d9c3618e Add regression tests for TLS. 2004-08-03 09:04:01 +00:00
pjd
adaa0482b4 Add GEOM_MIRROR class which provide RAID1 functionality and has many useful
features. The gmirror(8) utility should be used for control of this class.
There is no manual page yet, but I'm working on it with keramida@.

Many useful tests provided by:	simon (thank you!)
Some ideas from:		scottl, simon, phk
2004-07-30 23:13:45 +00:00
jkh
b050f5c62b After conferring with Apple legal, update the license of this to APSL 2.0
and change the URL link to point to the appropriate license text.
2004-07-27 20:01:43 +00:00
pjd
3a2f13d5f5 Change naming scheme from /dev/<name>.stripe to /dev/stripe/<name>. 2004-07-26 16:10:27 +00:00
pjd
badd010cc7 Change naming scheme from /dev/<name>.concat to /dev/concat/<name>. 2004-07-26 16:08:32 +00:00
rwatson
c5b9f7aaed Simple attachment regression test to attach the "accf_data" accept
filter to an inet socket and check at various points during the socket
life cycle that the filter can or cannot be attached, and that once
attached that the right one is attached and that it can be queried.
2004-07-26 03:53:47 +00:00
silby
c7a11c5dc2 Add two more programs useful for testing the correctness of pipes. 2004-07-22 02:46:25 +00:00
tjr
397b943e7a Add test programs for mbsnrtowcs() and wcsnrtombs(). 2004-07-21 13:47:48 +00:00
silby
d38e57366f Make this test compile again and remove its dependency on sys/pipe.h. 2004-07-21 03:13:53 +00:00
silby
da5b50a882 Add a simple regression test for the stat st_size bug just fixed in
sys_pipe.c
2004-07-20 07:17:19 +00:00
tjr
d3949c6f08 Add a skeleton makefile that runs the tests out of libc/regex/grot. 2004-07-19 09:00:26 +00:00
tjr
c977042a24 Oops, test error behaviour of wctrans(), not wctype(). 2004-07-19 08:53:41 +00:00
das
2408fa162f While testing fe[gs]etround(), make sure FLT_ROUNDS reflects the
proper rounding mode as well.
2004-07-19 08:17:47 +00:00
rwatson
bd6355261f Explicitly specify ATPROTO_DDP constant rather than '0' when binding
a netatalk socket.  No functional change.
2004-07-17 17:16:16 +00:00
rwatson
6bd2f3e42b Add a simple tool to bind netatalk sockets and perform send operations.
This isn't a classic regression test in that it doesn't have a notion of
pass fail, it's more of an exercise tool.  It attempts to exercise
unbound, bound, unconnected, and connected variations on SOCK_DGRAM
sockets.
2004-07-17 17:12:15 +00:00