Commit Graph

935 Commits

Author SHA1 Message Date
jruoho
957fb2eb62 "wrong return value" -> "wrong errno". 2011-04-10 10:59:13 +00:00
jruoho
ba788ede8f Currently known failures affect only amd64; adjust atf_tc_expect_fail(). 2011-04-10 10:23:45 +00:00
blymn
bdd37afa3f Add atf for libcurses with some tests 2011-04-10 09:55:08 +00:00
blymn
320b7b4d50 Add libcurses test 2011-04-10 09:49:13 +00:00
jruoho
5aac453263 A naive test case for getcwd(3). 2011-04-10 06:27:20 +00:00
jruoho
a63adaf81b Add a test case for PR lib/41931 reported by he@. It was verified that these
fail on NetBSD 5.99.48 amd64 but pass on amd64 Linux (glibc 2.7).
2011-04-10 06:11:47 +00:00
pgoyette
324074b933 atf-ify the various locale tests 2011-04-09 17:45:24 +00:00
jruoho
5ebf352487 Adjust the test with stdin(3). 2011-04-08 15:25:00 +00:00
jruoho
a2963f40dc Move the round(3) checks from 't_libm' to their own 't_round'
for consistency. Add -Wfloat-equal and fix comparisons.
2011-04-08 06:49:20 +00:00
jruoho
b63018ec52 Fix build failure on VAX. 2011-04-08 06:37:50 +00:00
jruoho
02dfa85f00 Remove the following (literal) text in the TNF copyrights:
* This code is derived from software contributed to The NetBSD Foundation
  * by
  *

XXX: If these originated from you and you want your name to be mentioned,
     please add it.
2011-04-07 18:14:08 +00:00
plunky
5a4807fa7d whitespace police 2011-04-07 08:29:50 +00:00
plunky
77d265be45 link libbluetooth tests to the build 2011-04-07 06:24:07 +00:00
plunky
38293af7ee add tests for the following libbluetooth functions
bluetooth(3)
	bt_aton()
	bt_ntoa()

    sdp_data(3)
	sdp_data_type()
	sdp_data_size()
	sdp_get_data()
	sdp_get_attr()
	sdp_get_uuid()
	sdp_get_bool()
	sdp_get_uint()
	sdp_get_int()
	sdp_get_seq()
	sdp_get_alt()
	sdp_get_str()
	sdp_get_url()
	sdp_match_uuid16()
	sdp_put_data()
	sdp_put_attr()
	sdp_put_uuid()
	sdp_put_uuid16()
	sdp_put_uuid2(3)
	sdp_put_uuid128()
	sdp_put_bool()
	sdp_put_uint()
	sdp_put_uint8()
	sdp_put_uint16()
	sdp_put_uint2(3)
	sdp_put_uint64()
	sdp_put_int()
	sdp_put_int8()
	sdp_put_int16()
	sdp_put_int2(3)
	sdp_put_int64()
	sdp_put_seq()
	sdp_put_alt()
	sdp_put_str()
	sdp_put_url()
	sdp_set_bool()
	sdp_set_uint()
	sdp_set_int()
	sdp_set_seq()
	sdp_set_alt()

[all pass on i386]
2011-04-07 06:21:57 +00:00
jruoho
64cf2356be Add a test case for the segfault reported in PR lib/43964. 2011-04-06 17:41:27 +00:00
jruoho
710017dde4 As per PR lib/44818, remove 'lib/libpthread/t_status'. It takes two minutes
to rewrite this properly if someone misses this.
2011-04-06 16:04:16 +00:00
jruoho
c212c60925 Mark this also as expected failure. 2011-04-06 10:06:49 +00:00
jruoho
9827f0b4f3 Formally verify the numerous bugs in humanize_number(3).
From PR lib/44097, by yamt@.
2011-04-06 10:04:53 +00:00
jruoho
e254abd58b A test case for PR lib/44057. 2011-04-06 09:35:49 +00:00
jruoho
e21f0b912e As there is PR lib/42587, mark tiny POSIX error as expected failure. 2011-04-06 08:47:55 +00:00
jruoho
2ae856efaa Verify the existence of PR lib/33262. 2011-04-06 07:25:34 +00:00
jruoho
01072bafe8 Rename some tests. No functional change. 2011-04-05 14:04:42 +00:00
jruoho
1cd1da49e9 Try to maintain the structure of libc and move 't_strtox' to 't_strtod'. 2011-04-05 08:24:28 +00:00
jruoho
e14810828f Add simple test cases for ttyname(3), strtod(3), and getgrent(3). 2011-04-05 06:15:30 +00:00
martin
b78cd4dd7c Do only set a (lower than default) timeout value if we are on powerpc and
expect to run into a real deadrun ofter.
The (too short) timeout otherwise makes slower archs fail.
2011-04-04 14:47:22 +00:00
jruoho
724a884379 Use _exit(2). 2011-04-04 10:30:29 +00:00
jruoho
bed8d3f065 Few simple tests for nice(3). 2011-04-04 09:52:17 +00:00
jruoho
d19079bc52 Add missing __RCSID(3), again. 2011-03-30 17:03:02 +00:00
jruoho
2289b490a3 Add some naive tests for the efun(3) family of debug functions. 2011-03-30 17:02:17 +00:00
he
6596e091ec Put tests depending on dlopen etc. under a test for MKPIC, and move
the corresponding entries in the set lists over to the shl.mi file.
This should bring the sun2 port back to a buildable state.
2011-03-30 11:43:15 +00:00
jruoho
a873c5cd55 Add missing __RCSID(3). 2011-03-30 08:34:19 +00:00
jmmv
e58081aa53 Halt the httpd server _before_ rump. Per pooka@'s suggestion. 2011-03-29 16:03:32 +00:00
jmmv
5bd1bce108 Make httpd create a pid file and use that to kill the server in a controlled
manner (instead of indirectly through rump.halt).  Suggested by pooka@.
2011-03-29 15:43:45 +00:00
jmmv
255271589f Extend pidfile(3) to support creating pid files in arbitrary locations.
If the argument provided to pidfile(3) contains a '/', then the value is
considered to be an absolute/relative path and the pid file is created
in the given location.

Otherwise, pidfile(3) behaves as before and treats the provided value as
a basename to construct a pid file in /var/run/<basename>.pid.  This means
that to create a pid file named "foo.pid" in the current directory, one
must specify "./foo.pid".
2011-03-29 13:55:37 +00:00
jruoho
1b871e25a1 Add a test case for pthread_cond_timedwait(3) failures reported by
Sad Clouds in PR lib/44756. This was discussed also in:

	http://mail-index.netbsd.org/tech-userlevel/2011/03/17/msg004689.html
2011-03-27 16:45:15 +00:00
jruoho
c90472ef80 Do not skip the QEMU bugs but instead mark these as expected failures. 2011-03-25 10:42:38 +00:00
jruoho
1604324802 Bluntly skip the tests that fail under QEMU. XXX: system(3) is used for this?
wnCVS: ----------------------------------------------------------------------
2011-03-25 10:00:31 +00:00
jruoho
0de4e7e46f Fix typo. 2011-03-25 09:39:19 +00:00
jruoho
88c2989461 Add some basic POSIX conformance tests for sched(3). 2011-03-25 09:34:02 +00:00
jruoho
5f8b364626 Even these naive test cases caught one (QEMU?) bug; comment PR # 44767. 2011-03-25 04:26:41 +00:00
jruoho
43a75470f9 Sort. 2011-03-24 16:58:01 +00:00
jruoho
629e716a41 Add a naive test case for raise(3). 2011-03-24 16:56:37 +00:00
jruoho
57842fd3b4 Add dummy test cases for ceil(3) and floor(3). It is expected that at least
one of these will fail on guest x86_64 NetBSD under Qemu. Thanks to pgoyette@
for checking the broken floor(16.999999...) = 17.
2011-03-24 15:43:06 +00:00
jruoho
68f3621e3d A dummy conformance-test for pthread_detach(3). I will extend this later. 2011-03-24 13:52:04 +00:00
jruoho
c3917926fd A dummy conformance-test of pthread_equal(3). 2011-03-24 12:40:59 +00:00
joerg
081dffd915 Explicitly terminate threads to prevent crashes on exit. 2011-03-23 13:57:04 +00:00
jmmv
a6fb334d92 Clean up some late-night braindeadness:
- Make the pidfile name generation functions return their value as a return
  value, not an output pointer.  And homogenize these into a single function.
- Free allocated memory.  Not truly necessary because the test cases die
  immediately anyway, but nice to do.
- Remove the pidfile__ prefix from test case names.  (This was in advance of
  some changes I want to propose to pidfile(3), but it turns out my approach
  was flawed.  Preemptive smartness is evil!)
2011-03-23 09:13:54 +00:00
jmmv
f8d6f5f369 Add some tests for pidfile(3).
I want to touch this module to attempt a feature addition but I need some
tests beforehand!
2011-03-22 23:07:32 +00:00
njoly
f031bfef0a Test case from PR/44189 should not fail anymore. 2011-03-22 22:29:18 +00:00
pooka
4975925b02 check that nfsd works with kernel module autoloading 2011-03-22 17:07:11 +00:00
pooka
3bc8d7931c test RUMPHIJACK fdoff=8 2011-03-14 15:56:40 +00:00
christos
2d8f83e77b Fix various vis/unvis issues:
- no need for all the weak symbols
- define a new _VIS_END flag for UNVIS_END so that there are no collisions
  between and vis and unvis flags.
- add bound versions of the vis and unvis functions that take the length of
  the destination buffer. Unlike the OpenBSD ones they return -1 or NULL if
  the buffer is not large enough, instead of silently truncating.
2011-03-12 19:52:45 +00:00
skrll
11c999cbce Deal with all objdir methods. 2011-03-10 14:31:07 +00:00
pooka
baaf9cb9d3 * remove juiblex from nfsd startup (i was using -DDEBUG nfsd yesterday)
* some minor nits
2011-03-10 13:42:33 +00:00
joerg
aad599979d Add TLS support infrastructure. For dynamic binaries, ld.elf_so exports
_rtld_tls_allocate and _rtld_tls_free. libpthread uses this functions to
setup the thread private area of all new threads. ld.elf_so is
responsible for setting up the private area for the initial thread.
Similar functions are called from _libc_init for static binaries, using
dl_iterate_phdr to access the ELF Program Header.

Add test cases to exercise the different TLS storage models. Test cases
are compiled and installed on all platforms, but are skipped on
platforms not marked for TLS support.

This material is based upon work partially supported by
The NetBSD Foundation under a contract with Joerg Sonnenberger.

It is inspired by the TLS support in FreeBSD by Doug Rabson and the
clean ups of the DragonFly port of the original FreeBSD modifications.
2011-03-09 23:10:05 +00:00
pooka
1bafe88e56 nfsd + mount_nfs test with stock system binaries 2011-03-09 21:25:59 +00:00
pooka
7e4239caf4 some blanket tests 2011-03-08 22:21:52 +00:00
pooka
5ec619238a test case for runon prefixes 2011-03-08 21:36:25 +00:00
pooka
a495c82c5f Enable the "send a lot of syscall requests before exec" code, since
it works now.  (or at least works in my tests)
2011-03-08 15:35:28 +00:00
pooka
fe92fa8193 print out the unexpected rv too 2011-03-08 14:53:03 +00:00
pooka
46dfa511bc add test case for multithreaded client calling exec 2011-03-08 12:40:25 +00:00
pooka
771df007e3 add tests for hijacked /bin/sh (mostly redirection now) 2011-03-03 11:54:11 +00:00
riz
1680d3ca61 Skip the sigfpe_flt and sigfpe_int tests on powerpc; powerpc does
not fault on divide-by-zero.  As discussed on tech-userlevel.
2011-03-02 03:42:56 +00:00
pooka
866d358b14 Attempt further qemu heuristics to avoid failures due to non-working FPU 2011-03-01 12:47:43 +00:00
pooka
e71885fb04 Create a pipe on which to select. selecting on STDIN_FILENO seems
to be succesful *sometimes* on some archs (i'm suspecting this is
in some way related to lib/libc/ttyio/t_ttyio failing).
2011-03-01 08:54:18 +00:00
pgoyette
bb1ec3c88c The ssp/raw test is useless. Remove it. 2011-02-26 02:41:33 +00:00
pgoyette
08b100965c Disable the "raw" test case. The test is bogus, and did not work before
conversion from src/regress/ to atf
2011-02-25 18:11:53 +00:00
pooka
2486194718 some tests for mv(1) 2011-02-23 16:38:08 +00:00
pooka
9f3340d97a simple vfs tests (mount ffs, cp/pax files there, un/remount,
check with diff)
2011-02-23 13:01:57 +00:00
riz
9613b94f2f mutex2/mutex3 are expected to fail on powerpc because of
PR port-powerpc/44387.

XXX the ugly sleep at the end is because ATF will mark an un-triggered
race condition (ie, the test passes unexpectedly) as a test failure otherwise.
2011-02-21 21:43:41 +00:00
pooka
f8da5a9891 check that poll on an invalid fd doesn't hang in the dual poll case 2011-02-20 23:45:46 +00:00
jmmv
15a3581f5e Adjust tests now that the values of atf_arch and atf_machine have been
reversed to carry their real intended meanings.

This is part of PR bin/44305.
2011-02-20 20:57:46 +00:00
jmmv
0553513a0e The mutex3 test is supposed to use a static initializer so that it differs
to the mutex2 test.  This detail was lost during the atfification of these
tests.

Spotted by pooka@ and riz@.
2011-02-20 14:37:44 +00:00
pooka
a7b761c335 Add a test that checks that the client receives SIGIO for an O_ASYNC
socket.
2011-02-20 13:27:46 +00:00
pooka
91a9bf9486 more test cases:
* // prefix
  * fchdir
  * cd-via-symlink
2011-02-19 19:57:28 +00:00
pooka
44ff4bdcb3 a basic getcwd() test 2011-02-19 13:19:52 +00:00
pooka
828eb9131f Run sockstat with -n so that difference in /etc/services don't
affect the test outcome.
2011-02-19 09:59:12 +00:00
pooka
5c6cde8ab3 RUMPHIJACK_RETRY -> RUMPHIJACK_RETRYCONNECT 2011-02-16 19:31:31 +00:00
pooka
1a01113004 test rumpclient_vfork() 2011-02-16 17:57:44 +00:00
pooka
daf96a009b no need to create a hardlinked name for the helper, just fake argv[] 2011-02-16 16:02:52 +00:00
pooka
9f22773c99 Don't use hijack here since exec is now easy in pure rump clients. 2011-02-16 15:34:18 +00:00
pooka
3f47eb3b3b remove unnecessary debug printf 2011-02-15 15:57:33 +00:00
pooka
36823968f7 test FD_CLOEXEC 2011-02-15 15:54:56 +00:00
pooka
fd59a0e429 add some exec() tests 2011-02-15 15:16:46 +00:00
pooka
3e3af76e8c explicitly set BLOCKSIZE so that we don't get fooled again 2011-02-14 19:56:30 +00:00
pooka
c754a0ea3b -debugging crud 2011-02-14 19:54:29 +00:00
pooka
e7ac403943 Test that hijacked ssh/sshd work.
Copypastes jmmv's sshd magic from fs/psshfs.
(dunno if it's worth sharing the code, or even what the
best practice for doing so would be)
2011-02-14 15:14:00 +00:00
pooka
e43200f113 Add test case from PR lib/44552 by Alexander Nasonov. I also lobbed
in a test for select(0, NULL, NULL, NULL, &tv) in there.
2011-02-12 10:28:08 +00:00
pooka
f9f796a4cf add test for fix in rev 1.36 of librumphijack/hijack.c 2011-02-11 15:38:14 +00:00
pooka
dab4b449d7 Add test which checks rumpclient does not use fds 0-2 for its
internal purposes.
2011-02-09 14:32:45 +00:00
pooka
fbc821a08c Add a simple test for the purpose of making sure rumphijack works
on -current in addition to 5.x.  The test serves a simple index.html
on a hijacked bozohttpd and checks the file can be retrieved.
2011-02-06 18:44:29 +00:00
pgoyette
7a60df3213 Moving t_hsearch - belongs in stdlib/ 2011-01-13 14:32:35 +00:00
pgoyette
4eb3e8521c Another test moving: lib/libc/t_inet --> lib/libc/inet/t_inet_network 2011-01-13 13:53:49 +00:00
pgoyette
c15f77f136 Last one for today: move t_ptm test from lib/libc/ to lib/libc/ttyio/ 2011-01-13 03:19:57 +00:00
pgoyette
542ee7575d Make sure we build all of thests, not just the last one (use += vs =) 2011-01-13 03:09:54 +00:00
pgoyette
9704d7e1f8 Repair some printf formats 2011-01-13 03:00:41 +00:00
pgoyette
1c807dbe53 Continuing the (re)organization of the lib/libc atf regression tests 2011-01-13 02:40:43 +00:00
pgoyette
ec5cad1d54 Re-add missing -lpthread and fix some structure inializers (not sure how
these ever compiled)
2011-01-13 02:24:51 +00:00
pgoyette
374d5969a4 The nsdispatch test belongs in libc/net and not in libc 2011-01-13 01:56:44 +00:00
pgoyette
004608e402 Move t_mktime and t_strptime to their own ..../time/ subdirectory.
(Concurrence from christos@)
2011-01-13 00:14:10 +00:00
pgoyette
6fdb369dfe Put the atexit test where it belongs - in libc/stdlib/ 2011-01-12 19:44:07 +00:00
pgoyette
2517c83d16 Move the servent and protoent tests to src/tests/lib/libc/net/ (where
they should have gone initially).
2011-01-12 17:32:27 +00:00
pgoyette
7755b90bc1 Now that the test has been placed in its new location, remove it from
the old
2011-01-12 03:00:28 +00:00
pgoyette
01a7ddb233 By request, put the getaddrinfo test in tests/lib/libc/net/ 2011-01-12 02:58:40 +00:00
pgoyette
c177834af5 Atf-ify the getaddrinfo test, with updated "golden" output files. 2011-01-11 16:30:53 +00:00
njoly
67aa333d97 Do close fd 4 in cerror_64 testcase too. 2011-01-10 16:54:02 +00:00
christos
880fe46bea remove clauses 3/4 2011-01-10 16:42:36 +00:00
christos
4e376e0546 make constant fit in 32 bits. 2011-01-10 05:15:00 +00:00
christos
37cdb63310 test for sigqueue 2011-01-10 04:57:56 +00:00
pgoyette
fdee497371 Fix typo that got lost between my trial build and the final commit 2011-01-09 05:44:46 +00:00
pgoyette
8d8e0a4616 Ouch - forgot the include this earlier. 2011-01-09 01:00:40 +00:00
pgoyette
17f9a364e6 Atf-ify the regex test 2011-01-08 18:10:31 +00:00
pgoyette
b607edaed3 Atf-ify the rpc/t_xdr test 2011-01-08 06:59:37 +00:00
pgoyette
27009b334d Fix and re-enable the delete_btree test case 2011-01-08 05:33:34 +00:00
pgoyette
0308b37ff4 Atf-ify the db tests.
XXX Note that the original regress version of this test did not run the
XXX btree_delete test; that test is broken, and is disabled for now.
2011-01-07 15:05:57 +00:00
pgoyette
62566a5bdc Atf-ify a couple more tests 2011-01-07 02:47:40 +00:00
pgoyette
8659b0cd02 Atf-ify test for mktime(3) 2011-01-06 17:20:48 +00:00
pgoyette
1eecbebf26 Atf-ify the nsdispath test. 2011-01-05 21:17:04 +00:00
pgoyette
8d8a62aedb Update the ieeefp tests so that they can be built on all architectures.
This enables us to avoid the set-list mess.

Build tested on amd64, i386, sun2, and vax!
2011-01-04 22:30:40 +00:00
pgoyette
ba8539611a Now that PR/44311 is fixed we can remove the expected-failure from this
test.
2011-01-04 12:44:48 +00:00
pgoyette
e81a7ec5fd Don't run FP Exception tests under qemu - they don't work.
While here, properly skip certain tests on vax architecture.  (It is
not legal to have a test-program with zero test cases, so each test
case needs to check-and-skip.)
2011-01-03 20:51:26 +00:00
pgoyette
39d0f69cf4 Ooopppsss - locale/ tests are not yet ready - don't SUBIDR yet 2011-01-03 19:25:48 +00:00
pgoyette
758e17089c Atf-ify the atexit test 2011-01-03 19:01:47 +00:00
dholland
41d09f7800 remove another extraneous static 2011-01-03 09:14:21 +00:00
dholland
9b8984c0e1 fix this properly. 2011-01-03 09:10:54 +00:00
pgoyette
6c188c10e6 Atf-ify servent and protoent tests, and the remaining hash test. 2011-01-02 22:03:25 +00:00
pgoyette
ddf58095f4 If we survive the check for wrong signal code, reset our expectation to
"pass" before checking the signal errno.
2011-01-02 21:39:24 +00:00
pgoyette
895e2a77b2 Fix $NetBSD$ keyword 2011-01-02 21:34:00 +00:00
christos
a8ca318180 avoid cloberring warning. 2011-01-02 21:17:19 +00:00
pgoyette
16618584e1 One more reference to HAVE_SIGINFO bites the dust 2011-01-02 18:28:36 +00:00
martin
7810b05eab Stopgap buildfix: gcc complains about test_ops possibly being clobbered
by sigjmp and I can't find a proper way to add -Wno-uninitialized in the
proper place in CFLAGS.
2011-01-02 13:49:15 +00:00
skrll
24c2d21be3 Whitespace. 2011-01-02 09:33:45 +00:00
pgoyette
f9886d18eb Atf-ify several of the ieeefp tests.
Note that t_round is currently mostly disabled, due to PR/44293.  Also,
testfloat has not been converted.
2011-01-02 03:51:20 +00:00
pgoyette
9a073313c7 Convert a few more tests from regress to atf 2011-01-01 23:56:48 +00:00
pgoyette
247905d351 Build t_ldexp test always. The test itself determines if it is running
on an unsupported platform (vax) and exits.
2011-01-01 23:45:01 +00:00
mlelstv
9f9ca3aac9 return from an SIGFPE handler is not defined when the hardware
caused the exception. Use sigsetjmp/siglongjmp to resume the
test function instead.
2010-12-31 14:54:55 +00:00
pgoyette
b9bd4f1954 Moving more tests out of regress and into atf mainstream 2010-12-31 14:36:10 +00:00
pgoyette
5c6d42ce59 Ooopppsss - ieefp tests have not been atf-ified, so remove the stuff
that got committed by mistake.
2010-12-31 05:05:43 +00:00
pgoyette
ea706db02e Migrate a few miscellaneous tests from the old regress to atf 2010-12-31 04:08:32 +00:00
pooka
2febaa74cc Test is no longer expected to hang.
PR lib/44248 closed when test associate with PR fails ==> brick dholland
2010-12-30 22:21:53 +00:00
pgoyette
271a24bb60 Fix name of t_ldexp test from previous 2010-12-28 20:25:31 +00:00
pgoyette
404ccc33e0 Don't build ldexp tests on vax 2010-12-28 17:33:58 +00:00
pgoyette
238e3baebf Migrate the ldexp test to atf 2010-12-28 16:57:00 +00:00
christos
ba385e83d4 allocate the buffer at the same function level as the compiler so that
the compiler knows to emit the right _chk call.
2010-12-28 16:18:46 +00:00
pgoyette
66bfd22447 Migrate the remaining libc/gen tests to atf 2010-12-28 12:46:15 +00:00
pgoyette
cfe38ef780 Move the various setjmp tests from regress to atf 2010-12-27 19:35:30 +00:00
njoly
3e3a3e290e Do use integer arithmetics to generate FPE_INTDIV in sigfpe_int testcase.
Ok pgoyette.
2010-12-27 15:24:13 +00:00
he
f806491146 Don't try to build the SSP tests if the target doesn't have SSP. 2010-12-27 15:10:33 +00:00
pgoyette
e2d4656741 Since atf_check doesn't deal with a pipeline, modify the tests to pipe
the output of the echo commands to atf_check itself.  This fixes the
three new ssp failures.

Note that the raw, strcpy, vsprintf, and vsnprintf tests still fail, but
they failed in the old 'regress' style, too.
2010-12-27 05:27:34 +00:00
pgoyette
575e75ffe4 Migrate the ssp tests from regress to atf.
Of the 17 tests, 4 fail in both the regress and atf style.  3 additional
tests fails in atf that did NOT fail in regress: gets, fgets, and read.
I will investigate why, and update when I can, but it is still useful to
get these tests into the new format where they can be exercised.
2010-12-27 02:04:18 +00:00
pgoyette
3ca5a7db69 Migrate the last of the libc/string/ tests from regress to atf, and
re-enable building of t_popcount
2010-12-26 13:35:54 +00:00
pgoyette
a583a258c9 Make running this test conditional on the setting of atf configuration
variable "run_popcount".  This is a really long-running test (it takes
several hours on a qemu-emulation on a 2.8GHz AMD Pheno II) but could
still be useful if you want to run it manually, with the command

	atf-run -v run_popcount=YES
2010-12-26 13:29:47 +00:00
pgoyette
3f7804c696 Re-enable printing of MD data, with appropriate casts. 2010-12-26 12:32:28 +00:00
pgoyette
324775a6d1 For now, don't try to print out machine-dependant stuff. When I figure
out what the right format strings are, I'll re-enable it.
2010-12-26 03:25:07 +00:00
pgoyette
f03970fd11 Migrate J.T.Conklin's public-domain str* tests from regress to atf.
While here, do some clean-up and knf.
2010-12-25 21:10:24 +00:00
pgoyette
b1084f5b5e Correctly added the conditional part, but now need to remove the original
unconditional part.
2010-12-25 01:25:37 +00:00
pgoyette
dcfc8e943b Don't include the siginfo tests unless we actually have siginfo ability! 2010-12-25 01:22:02 +00:00
pgoyette
de2970929a Move the siginfo tests from regress to atf. While here, add a new test
for PR/43655.

XXX The sigchild_dump test currently fails when execute under atf-run.
XXX It does not fail when executed directly from the shell, so there's
XXX something in atf that prevents the child process from dumping.
2010-12-25 01:04:26 +00:00
pgoyette
546ea3ce2c Migrate a couple more tests to aft 2010-12-23 15:27:44 +00:00
pgoyette
bf59258ffb Fix the $NetBSD$ tag (missed the trailing $) 2010-12-23 13:34:46 +00:00
pgoyette
95456adcc6 Migrate a couple more tests from the old regress structure to atf 2010-12-22 23:45:44 +00:00
pgoyette
ad537a3656 Migrate a few more tests from old regress style to atf 2010-12-21 14:23:42 +00:00
christos
1f98304948 We don't expect tests to fail anymore. 2010-12-21 00:24:14 +00:00
pgoyette
e02d91d677 Move the only regress/lib/libm test to the new atf format 2010-12-20 23:47:23 +00:00
njoly
198de556b0 Add testcase from PR/44255, that exercize parsedate(3) with sample
strings taken from the manpage.
2010-12-20 16:23:01 +00:00
pooka
afe2ac389d Add an isolated test case for PR lib/44248. 2010-12-17 19:12:30 +00:00
joerg
31b95753a0 Simplify 2010-12-12 18:21:21 +00:00
joerg
1b0b455148 Link t_fpu against libm if the compiler doesn't want to inline sin/cos. 2010-12-08 23:50:14 +00:00
joerg
994bc56774 Kill file that should be pulled in from a different directory.
Fixes regression test for i386.
2010-12-07 00:54:44 +00:00
pooka
335d54d634 Adjust PR format in xfail message so that html test results gain a
link to http://gnats.netbsd.org/44189
2010-12-06 17:30:07 +00:00
joerg
65b45bb0d8 Actually add the check_stack_alignment implementation for x86. 2010-12-03 20:51:21 +00:00
njoly
71281c77f5 Add testcase for PR/44189: strtod(3) wrong results with "-0x". 2010-12-03 13:11:50 +00:00
pooka
fe64a82d7b comment why vax is left out of all the fun 2010-12-01 07:12:03 +00:00
joerg
236a44094d Test alignment of constructor / destructor calls as well as the stack
of new threads. Currently implement for i386 and AMD64.
2010-11-30 18:38:53 +00:00
pgoyette
67b7416103 Revert previous. The atf default timeout has been reverted, and the 90sec
timer I imposed here is still sometimes "not quite long enough" for the
tests to complete in an amd64 qemu/anita environment.
2010-11-29 18:21:15 +00:00
mrg
9dd1efa373 vax doesn't have ieee fp, so, don't try to test ieee fp on vax. 2010-11-22 08:47:58 +00:00
njoly
c8fe673676 Add testcase for PR/44113: printf(3) should ignore zero padding for
nan/inf.
2010-11-19 18:18:53 +00:00
tron
40d1f42309 Put my name in the author section. 2010-11-17 08:55:27 +00:00
tron
55e8419d17 Split threaded environment test for the other environment tests as
suggested by Nicolas Joly in private e-mail. Linking a binary with
"libpthread" effects the beaviour of "libc" and we really want to
test both cases.
2010-11-16 14:03:47 +00:00
tron
91e8290e88 Add a new regression test "t_threaded" which tests using getenv_r(3),
putenv(3), setenv(3) and unsetenv(3) concurrently.
2010-11-14 19:19:24 +00:00
tron
18217b5088 Update tests for *env(3):
- Introduce randomness into "t_setenv" to avoid freeing environment
  variables exactly in the order they have been allocated.
  Also call unsetenv(3) twice to make sure it behaves well if the
  environment variable doesn't exist.
- "t_getenv" is no longer a known failure after getenv(3) and getenv_r(3)
  have been fixed.
2010-11-14 18:15:08 +00:00
tron
603058a76c Add a test for getenv(3) which fails at the moment because it doesn't
handle "=" in variable names properly.

I'll send out a diff for review soon which fixes this.
2010-11-13 21:08:36 +00:00
tron
926ab269df Improve testing of environment handling:
1.) Always check the return value of setenv(3) and unsetenv(3).
2.) Test that calling setenv(..., ..., 0) doesn't overwrite environment
    variables.
3.) Add a new test which mixes putenv(3) and setenv(3).
2010-11-13 18:52:55 +00:00
pgoyette
1c0f72e4dd The libevent tests are fairly lengthy - each test case actually contains
about 20 or so mini-cases.  Increase the timeout for these tests to let
them run to completion.
2010-11-11 22:18:53 +00:00
pooka
dbfa9a01cc Now that copyinstr() correctly returns error, trim the semaphore
name to fit into SEM_MAX_NAMELEN.
2010-11-10 11:14:12 +00:00
pooka
92603a1ff0 This test is cursed.
Yesterday I thought I committed the increased timeout and when the
test was still failing for the autotests n hours later I noticed
I had actually failed to commit it.  I did manage to commit something
in the evening, but the autotests were still failing this morning,
so I noticed I increased the timeout of the wrong test.  I wonder
what will go wrong this time...

(and p.s.: 10240 is probably slow because it's O(n^2) with a constant
of quite a few)
2010-11-09 11:48:35 +00:00
pooka
537f9e3a0b Increase timeout from 30 to 300 since this test runs for a long time.
XXX1: should 2x10240 loops really be *that* slow?
XXX2: is 10240 a sensible number to begin with?
2010-11-08 23:28:41 +00:00
njoly
e7d0fdd058 Do not fail but skip tests if POSIX semaphores are not supported. 2010-11-08 13:05:49 +00:00
jmmv
decf2b5e0f Adjusts tests after import of atf-0.12:
- The use.fs property is gone.
- Mark the tests/fs/t_create:attrs test as broken when using the default
  unprivileged-user:_atf setting.  This probably deserves a fix somehow
  but I'm not sure at this point.
2010-11-07 17:51:16 +00:00
christos
b32d0df211 disable string again 2010-11-03 20:20:12 +00:00
christos
0f10aa9dce add Makefile.inc everywhere so that we can set WARNS=4 by default. Amazing
how many bugs this found :-)
2010-11-03 16:10:19 +00:00
christos
d3d3da9ee3 add a clearenv test. 2010-11-03 16:09:43 +00:00
njoly
5d63576039 Make putenv(3) fails with EINVAL for a null pointer, or for a string
that either miss or start with a `=' character.

Adjust man page and testcase accordingly.
2010-10-25 20:35:36 +00:00
njoly
4c968434a3 Make setenv(3) follow the standard, by rejecting invalid strings. It
now fails with EINVAL errno when variable is NULL, empty or contains
an `=' character; or value is NULL.

Adjust the man page accordingly, and exercize them in the existing
environment testcase.
2010-10-16 11:23:41 +00:00
pooka
936f8998cf Use actual buffer size instead of sizeof(char *). Makes the test
work on non-64bit platforms.
2010-10-13 11:19:28 +00:00
pooka
6dec45da47 fix -DDEBUG 2010-10-13 10:31:00 +00:00
christos
6188013961 use "RZ()" instead of ATF_CHECK(), since ATF_CHECK does not deal with errno.
This is repulsive, specially the part about hard-coding the h_macros.h file
in the c code.
2010-10-11 15:48:57 +00:00
christos
99101ab637 don't use err(), from pooka.
CV: ----------------------------------------------------------------------
2010-10-11 15:16:01 +00:00
christos
37a7ff776d Add tests for putenv(3) 2010-10-01 20:12:20 +00:00
tnozaki
93b7363c93 add fmemopen(3) derrived from POSIX:2008.
libc minor bump.
2010-09-24 09:21:53 +00:00
christos
1db2d29e54 unit test for environment. Grr, someone should make fixing the sets easier
otherwise people are not going to want to write unit-tests.
2010-09-23 17:38:08 +00:00
christos
5472a32d66 glue glob tests 2010-09-09 22:25:38 +00:00
christos
758507e1aa Add tests for GLOB_STAR 2010-09-06 14:41:21 +00:00
jmmv
b283757fe6 Convert the libdes tests to atf. 2010-08-25 16:46:36 +00:00
joerg
4dfb749204 Rename h_initfini3 dso now that it is a simple module. 2010-08-04 14:59:39 +00:00
joerg
21847f857f Simplify. 2010-08-04 13:56:10 +00:00
joerg
b6fbda43e7 TESTSBASE is provided by bsd.own.mk now. 2010-08-04 13:52:23 +00:00
hans
846cca4cda Revert to 1.1 and fix the casts by using uintptr_t. Ok jruoho. 2010-07-29 12:56:16 +00:00
jruoho
f560676c53 One more cast. 2010-07-29 12:17:31 +00:00
jruoho
07456be22e Fix build failure on AMD64, noted by njoly@. 2010-07-29 12:03:10 +00:00
jruoho
b226f3d0e3 Add a simple test for pthread_join(3). 2010-07-28 21:29:15 +00:00
joerg
cee90d4c4c Replace csu test case with a C++ based version. This makes the various
assembler routines obsolete. Be more exhaustive by testing dynamically
linked, statically linked and dynamically loaded.

XXX currently hard-codes /usr/tests due to limitations of bsd.test.mk
2010-07-28 13:51:38 +00:00
jmmv
8a0380e301 before_start_one_thread is not racy only in amd64; my confusion. Mark it
as an xfail everywhere and, while doing so, make the test longer so that
we trigger the failure all the time -- of course, being a race this may
still happen but the chances should be pretty low.
2010-07-21 17:23:08 +00:00
jmmv
28cce38f11 Split the before_start test in two: one that does not use threads and one
that does.  The former works all the time but the latter gets consistently
stuck on amd64.  Mark the latter as an expected timeout (should be a "race
condition" test, but atf does not have such a thing yet[1]).

This clears the test failures, at least, under anita running NetBSD/i386.

From pooka@: this could well be because calling sem_post(3) from a signal
handler can't possibly do the right thing with the pthread implementation.
However, according to signal(7), sem_post(3) is signal-async safe...

While here, program alarms using a timeout shorter than 1 second to speed
up the execution of the tests.

1: Good thing is I finally understand what a "race condition" test looks
like, I believe.
2010-07-19 10:31:46 +00:00
pooka
510b2ec795 Reduce sleep time for practically the same effect. Until atf can
do parallel test execution, tests which spend 99.9999% of their
execution sleeping are not nice.
2010-07-18 22:30:55 +00:00
jmmv
cb5d4b0864 Convert the libobjc tests to atf. While doing this, make the tests actually
check that things work.
2010-07-18 12:41:51 +00:00
jmmv
bbd81cb35e Convert the csu tests to atf.
Initial work from the GSoC 2008 project by Lukasz Strzygowski.
2010-07-17 19:25:26 +00:00
njoly
ffa14f5342 Add missing pthread_mutex_init call in mutex3 testcase. 2010-07-16 18:16:43 +00:00
jmmv
ac555471ca Convert the libpthread tests to atf.
Initial work from the GSoC 2008 project by Lukasz Strzygowski.

I think that this, together with the previous conversion of librt, obsoletes
the tests in the semaphore/ directory.  Will investigate later.
2010-07-16 15:42:53 +00:00
jmmv
c505c44298 Convert the libposix, libprop, librt, libskey and libutil tests to ATF.
Initial work from the GSoC 2008 project by Lukasz Strzygowski.
2010-07-16 13:56:31 +00:00
jmmv
9d0b4b5bb8 Get rid of static Atffiles and let bsd.test.mk generate them on the fly. 2010-07-13 21:13:21 +00:00
jmmv
7562f3f929 Replace custom xfail settings with the new expected failure support in
atf 0.10.
2010-07-03 08:18:30 +00:00
pooka
de8c66c7a5 * remove pasto
* set short timeout for the blockwait test
2010-06-17 09:37:50 +00:00
pooka
a17a919421 Set xfail for tests which have a PR for them. 2010-06-16 15:39:41 +00:00
pooka
7bf6b262ee Function which does not return needs to return a value. 2010-06-12 22:59:59 +00:00
pooka
693b5f6213 quote PR kern/43452 in descr 2010-06-10 22:20:38 +00:00
pooka
b2077c0c11 Add tests for semaphores. Note: the "unlink" one fails because our
implementation is broken.  I'll file a PR shortly.
2010-06-10 22:03:43 +00:00
martin
5d2d1246bd remove "string" directory for now, it isn't installed 2010-02-28 11:06:59 +00:00
martin
163086bd7a Disable population count test for now, please re-enable once
PR toolchain/42885 is fixed
2010-02-26 09:35:08 +00:00
joerg
1ca41e3237 Add a regression test for the SHA2 family that also checks for unaligned
accesses.
2010-01-24 21:12:17 +00:00
plunky
b2965573f9 add ATF tests for libevent 2009-11-02 10:15:45 +00:00
drochner
55f6a48c74 flag a 64-bit integer constant as "ULL" -- this is not clean but the
code around it assumes it anyway
fixes build on 32-bit
2009-07-21 21:45:33 +00:00
joerg
974b291a6c Add popcount(3) and the long and long long version. Name is inspired by
gnulib, the implementation goes back to the AMD Software Optimizer
guide. A number of platforms will want to replace the C version with
assembler code using native instructions.
2009-07-21 13:18:43 +00:00
joerg
7afbfeabf4 Use __RCSID. 2009-07-20 18:24:01 +00:00
joerg
d6e219476b Add a fast, platform independent hash function to libc.
The algorithm used is the Jenkins hash.  The name (mi_vector_hash)
reflects the nature of the hash function.
Add glue for libc ATF tests and include a test case to make sure that
(mis)alignment and endianess are handled correctly.

Bump libc minor to 169.
2009-07-20 17:03:36 +00:00