Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 27 Oct 2000 08:40:36 +0000 (GMT)
From:      Terry Lambert <tlambert@primenet.com>
To:        tsuchiya@flab.fujitsu.co.jp
Cc:        freebsd-fs@FreeBSD.ORG
Subject:   Re: validation tool?
Message-ID:  <200010270840.BAA25886@usr09.primenet.com>
In-Reply-To: <200010270245.LAA05189@aiko.kawasaki.flab.fujitsu.co.jp> from "tsuchiya@flab.fujitsu.co.jp" at Oct 27, 2000 11:45:38 AM

next in thread | previous in thread | raw e-mail | index | archive | help
> Is there any validation tool, that checks if system calls work as 
> written in man pages? 
> We have developed a file system and would like to know if it returns 
> right errors in various conditions.

The SVID III validation suite will do this for SVID compliant
UNIX systems (SVR4 derived systems); it is only available under
license, and requires TET (Test Environment Toolkit), which is
free.

There is also the PCTS (POSIX Conformance Test Suite), which is
published by the U.S. NIST (National Institute of Standards and
Technology).  This is available for free download; you can find
it by going to Altavist and querying for:

	+PCTS +NIST +download

I have also written a tool, which others have updated.  It is a
test framework, whose intent is to look for kernel memory leaks
by examining memory allocations in the kernel before and after
system calls.  It's probably not what you are looking for, but
it's called "TESTSET", and is available from:

	http://people.FreeBSD.org/~terry/testset.txt
	http://people.FreeBSD.org/~terry/testset.tar.gz.uu

It could be useful for a file system, since they do allocations
and deallocations, but you will need to round-trip the code.

If you are going to "roll your own", I would strongly recommend
using "TET", or better, "ETET", as a basis for your testing
framework (both are a product of the now defunct UNIX International,
which I saved before their FTP server went down; they are now all
over the net in various places, but the canonical location is at
Digiboard's FTP server).

Finally, there is C++ code available in the comp.sources.unix
archives, which is capable of doing branch path validation on C
code.  You basically run your code through the C preprocessor to
strip out any occurances of unexpanded macros, and then run the
program on it.  It will create test cases for every branch path
in the code, and this will mean that the tests it generates will
have 100% code coverage.  You will have to either run the code
in kernel space with the FS, or you will have to have glue code
that packages up the calls into system calls which, when they are
unpackaged by the kernel, will result in the same function calls
against the branch path.  Sorry, but FreeBSD still doesn't support
user mode debugging of VFS modules, at this time (I could tell you
what you'd have to do to support that, if you wanted, as well, but
it is primarily not useful on anything but pure stacking layers,
unless you do a lot of work to implement the bottom end kernel
interface emulation in user space).

Hope this helps..


					Terry Lambert
					terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-fs" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200010270840.BAA25886>