NetBSD Problem Report #45038

From yamt@NetBSD.org  Fri Jun 10 05:49:40 2011
Return-Path: <yamt@NetBSD.org>
Received: by www.NetBSD.org (Postfix, from userid 1270)
	id 1790663BA4F; Fri, 10 Jun 2011 05:49:40 +0000 (UTC)
Message-Id: <20110610054940.1790663BA4F@www.NetBSD.org>
Date: Fri, 10 Jun 2011 05:49:40 +0000 (UTC)
From: yamt@NetBSD.org
Reply-To: yamt@NetBSD.org
To: gnats-bugs@NetBSD.org
Subject: lack of tests options
X-Send-Pr-Version: 3.95

>Number:         45038
>Category:       misc
>Synopsis:       lack of tests options
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    njoly
>State:          closed
>Class:          doc-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Jun 10 05:50:00 +0000 2011
>Closed-Date:    Fri Jun 17 08:44:07 +0000 2011
>Last-Modified:  Fri Jun 17 08:44:07 +0000 2011
>Originator:     YAMAMOTO Takashi
>Release:        NetBSD current
>Organization:

>Environment:


System: NetBSD current
Architecture: i386
Machine: i386
>Description:
	i always fail to remember the fstype= option in the following.

		cd /usr/tests/fs/vfs; atf-run -v fstype=nfs|atf-report

	probably options like this should be documented in tests(7)?
>How-To-Repeat:

>Fix:


>Release-Note:

>Audit-Trail:
From: Julio Merino <jmmv@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: yamt@NetBSD.org, misc-bug-people@netbsd.org, gnats-admin@netbsd.org, 
 netbsd-bugs@netbsd.org
Subject: Re: misc/45038: lack of tests options
Date: Fri, 10 Jun 2011 08:09:20 +0100

 On 6/10/11 6:50 AM, yamt@NetBSD.org wrote:
 >> Number:         45038
 >> Description:
 > 	i always fail to remember the fstype= option in the following.
 >
 > 		cd /usr/tests/fs/vfs; atf-run -v fstype=nfs|atf-report

 Is that option _required_?  If it is, and there is no default value, 
 then there is something wrong.

 You can also put your desired value in /etc/atf/NetBSD.conf and forget 
 about it ;-)

 > 	probably options like this should be documented in tests(7)?

 Sounds like a good idea.

 -- 
 Julio Merino / @jmmv

From: yamt@mwd.biglobe.ne.jp (YAMAMOTO Takashi)
To: jmmv@NetBSD.org
Cc: gnats-bugs@NetBSD.org, yamt@NetBSD.org, misc-bug-people@netbsd.org,
	gnats-admin@netbsd.org, netbsd-bugs@netbsd.org
Subject: Re: misc/45038: lack of tests options
Date: Fri, 10 Jun 2011 07:35:03 +0000 (UTC)

 > On 6/10/11 6:50 AM, yamt@NetBSD.org wrote:
 >>> Number:         45038
 >>> Description:
 >> 	i always fail to remember the fstype= option in the following.
 >>
 >> 		cd /usr/tests/fs/vfs; atf-run -v fstype=nfs|atf-report
 > 
 > Is that option _required_?  If it is, and there is no default value, 
 > then there is something wrong.

 no, it isn't required.

 the option merely saves my time when i'm not interested in
 testing other filesystems.

 YAMAMOTO Takashi

 > 
 > You can also put your desired value in /etc/atf/NetBSD.conf and forget 
 > about it ;-)
 > 
 >> 	probably options like this should be documented in tests(7)?
 > 
 > Sounds like a good idea.
 > 
 > -- 
 > Julio Merino / @jmmv

From: Nicolas Joly <njoly@pasteur.fr>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 15:21:55 +0200

 --uAKRQypu60I7Lcqm
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline

 On Fri, Jun 10, 2011 at 05:50:00AM +0000, yamt@NetBSD.org wrote:
 > >Number:         45038
 > >Category:       misc
 > >Synopsis:       lack of tests options
 > >Confidential:   no
 > >Severity:       non-critical
 > >Priority:       low
 > >Responsible:    misc-bug-people
 > >State:          open
 > >Class:          doc-bug
 > >Submitter-Id:   net
 > >Arrival-Date:   Fri Jun 10 05:50:00 +0000 2011
 > >Originator:     YAMAMOTO Takashi
 > >Release:        NetBSD current
 > >Organization:
 > 	
 > >Environment:
 > 	
 > 	
 > System: NetBSD current
 > Architecture: i386
 > Machine: i386
 > >Description:
 > 	i always fail to remember the fstype= option in the following.
 > 
 > 		cd /usr/tests/fs/vfs; atf-run -v fstype=nfs|atf-report
 > 
 > 	probably options like this should be documented in tests(7)?

 Hi,

 Does the following patch fit your needs ?

 Thanks.

 -- 
 Nicolas Joly

 Projects and Developments in Bioinformatics
 Institut Pasteur, Paris.

 --uAKRQypu60I7Lcqm
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: attachment; filename="netbsd-testsman.diff"

 Index: share/man/man7/tests.7
 ===================================================================
 RCS file: /cvsroot/src/share/man/man7/tests.7,v
 retrieving revision 1.4
 diff -u -p -r1.4 tests.7
 --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 +++ share/man/man7/tests.7	16 Jun 2011 13:19:28 -0000
 @@ -163,6 +163,16 @@ The suite-specific configuration file im
  which contains properties shared among all test suites.
  These files conform to the configuration file format described in
  .Xr atf-formats 5 .
 +.Pp
 +The following configuration variables are available in the
 +.Nx
 +test suite :
 +.Bl -tag -width "fstype"
 +.It fstype
 +When set to a filesystem type, restrict tests programs from the
 +.Pa /usr/tests/fs/vfs
 +tree to only run test cases for the given type.
 +.El
  .Ss What to do if something fails?
  If there is
  .Em any failure

 --uAKRQypu60I7Lcqm--

From: Julio Merino <jmmv@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: Nicolas Joly <njoly@pasteur.fr>, misc-bug-people@netbsd.org, 
 gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 14:44:21 +0100

 On 6/16/11 2:25 PM, Nicolas Joly wrote:
 >  Hi,
 >  
 >  Does the following patch fit your needs ?

 Looks nice!  Some minor comments:

 >  Index: share/man/man7/tests.7
 >  ===================================================================
 >  RCS file: /cvsroot/src/share/man/man7/tests.7,v
 >  retrieving revision 1.4
 >  diff -u -p -r1.4 tests.7
 >  --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 >  +++ share/man/man7/tests.7	16 Jun 2011 13:19:28 -0000

 Don't forget to bump the date.

 >  @@ -163,6 +163,16 @@ The suite-specific configuration file im
 >   which contains properties shared among all test suites.
 >   These files conform to the configuration file format described in
 >   .Xr atf-formats 5 .
 >  +.Pp
 >  +The following configuration variables are available in the
 >  +.Nx
 >  +test suite :
 >  +.Bl -tag -width "fstype"
 >  +.It fstype
 >  +When set to a filesystem type, restrict tests programs from the
 >  +.Pa /usr/tests/fs/vfs

 I'd add a trailing slash here to denote a directory.

 >  +tree to only run test cases for the given type.
 >  +.El

 Also document the unprivileged_user option.  It's used explicitly by
 some tests.  (It defaults to _atf.)

 >   .Ss What to do if something fails?
 >   If there is
 >   .Em any failure

 Lastly, it may be worth to note that these settings go into
 /etc/atf/NetBSD.conf .  Not sure if this is already mentioned in the
 manpage.

 -- 
 Julio Merino / @jmmv

From: Nicolas Joly <njoly@pasteur.fr>
To: Julio Merino <jmmv@NetBSD.org>
Cc: gnats-bugs@NetBSD.org, Nicolas Joly <njoly@pasteur.fr>,
	misc-bug-people@netbsd.org, gnats-admin@netbsd.org,
	netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 16:52:50 +0200

 On Thu, Jun 16, 2011 at 02:44:21PM +0100, Julio M. Merino Vidal wrote:
 > On 6/16/11 2:25 PM, Nicolas Joly wrote:
 > >  Hi,
 > >  
 > >  Does the following patch fit your needs ?
 > 
 > Looks nice!  Some minor comments:
 > 
 > >  Index: share/man/man7/tests.7
 > >  ===================================================================
 > >  RCS file: /cvsroot/src/share/man/man7/tests.7,v
 > >  retrieving revision 1.4
 > >  diff -u -p -r1.4 tests.7
 > >  --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 > >  +++ share/man/man7/tests.7	16 Jun 2011 13:19:28 -0000
 > 
 > Don't forget to bump the date.

 Will do. Thanks for the reminder.

 > >  @@ -163,6 +163,16 @@ The suite-specific configuration file im
 > >   which contains properties shared among all test suites.
 > >   These files conform to the configuration file format described in
 > >   .Xr atf-formats 5 .
 > >  +.Pp
 > >  +The following configuration variables are available in the
 > >  +.Nx
 > >  +test suite :
 > >  +.Bl -tag -width "fstype"
 > >  +.It fstype
 > >  +When set to a filesystem type, restrict tests programs from the
 > >  +.Pa /usr/tests/fs/vfs
 > 
 > I'd add a trailing slash here to denote a directory.

 Done.

 > >  +tree to only run test cases for the given type.
 > >  +.El
 > 
 > Also document the unprivileged_user option.  It's used explicitly by
 > some tests.  (It defaults to _atf.)

 I don't find it anywhere. Is it "require.user" = "unprivileged" ? 

 IMHO, we should only document in tests(7) the configuration variables
 which are not part of ATF.

 > >   .Ss What to do if something fails?
 > >   If there is
 > >   .Em any failure
 > 
 > Lastly, it may be worth to note that these settings go into
 > /etc/atf/NetBSD.conf .  Not sure if this is already mentioned in the
 > manpage.

 It is, a few lines before my patch.

 But for `fstype' it should not (at least in most cases) go into
 NetBSD.conf; otherwise, you'll always skip most of the vfs tests.  It
 much more useful to be added to the atf-run command for specific
 testing, by example for exercising a specific filesystem when working
 on it.

 -- 
 Nicolas Joly

 Projects and Developments in Bioinformatics
 Institut Pasteur, Paris.

From: Julio Merino <jmmv@NetBSD.org>
To: Nicolas Joly <njoly@pasteur.fr>
Cc: gnats-bugs@NetBSD.org, misc-bug-people@netbsd.org, 
 gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 16:01:12 +0100

 On 6/16/11 3:52 PM, Nicolas Joly wrote:
 > On Thu, Jun 16, 2011 at 02:44:21PM +0100, Julio M. Merino Vidal wrote:
 >> On 6/16/11 2:25 PM, Nicolas Joly wrote:
 >>>  Hi,
 >>>  
 >>>  Does the following patch fit your needs ?
 >>
 >> Looks nice!  Some minor comments:
 >>
 >>>  Index: share/man/man7/tests.7
 >>>  ===================================================================
 >>>  RCS file: /cvsroot/src/share/man/man7/tests.7,v
 >>>  retrieving revision 1.4
 >>>  diff -u -p -r1.4 tests.7
 >>>  --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 >>>  +++ share/man/man7/tests.7	16 Jun 2011 13:19:28 -0000
 >>
 >> Don't forget to bump the date.
 > 
 > Will do. Thanks for the reminder.
 > 
 >>>  @@ -163,6 +163,16 @@ The suite-specific configuration file im
 >>>   which contains properties shared among all test suites.
 >>>   These files conform to the configuration file format described in
 >>>   .Xr atf-formats 5 .
 >>>  +.Pp
 >>>  +The following configuration variables are available in the
 >>>  +.Nx
 >>>  +test suite :
 >>>  +.Bl -tag -width "fstype"
 >>>  +.It fstype
 >>>  +When set to a filesystem type, restrict tests programs from the
 >>>  +.Pa /usr/tests/fs/vfs
 >>
 >> I'd add a trailing slash here to denote a directory.
 > 
 > Done.
 > 
 >>>  +tree to only run test cases for the given type.
 >>>  +.El
 >>
 >> Also document the unprivileged_user option.  It's used explicitly by
 >> some tests.  (It defaults to _atf.)
 > 
 > I don't find it anywhere. Is it "require.user" = "unprivileged" ? 

 Ah sorry, it's unprivileged-user.

 > IMHO, we should only document in tests(7) the configuration variables
 > which are not part of ATF.

 Well, I guess this one is a bit of a compromise.  unprivileged-user was
 _not_ an atf-specific variable; it used to be defined by NetBSD only.
 These days, it has a special meaning in atf itself, but some NetBSD
 tests query it directly to do their own stuff.  In other words, it is
 not only used by require.user=unprivileged, but also to perform some
 specific actions in the tmpfs tests.

 -- 
 Julio Merino / @jmmv

From: Nicolas Joly <njoly@pasteur.fr>
To: Julio Merino <jmmv@NetBSD.org>
Cc: Nicolas Joly <njoly@pasteur.fr>, gnats-bugs@NetBSD.org,
	misc-bug-people@netbsd.org, gnats-admin@netbsd.org,
	netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 17:12:52 +0200

 On Thu, Jun 16, 2011 at 04:01:12PM +0100, Julio M. Merino Vidal wrote:
 > On 6/16/11 3:52 PM, Nicolas Joly wrote:
 > > On Thu, Jun 16, 2011 at 02:44:21PM +0100, Julio M. Merino Vidal wrote:
 > >>
 > >> Also document the unprivileged_user option.  It's used explicitly by
 > >> some tests.  (It defaults to _atf.)
 > > 
 > > I don't find it anywhere. Is it "require.user" = "unprivileged" ? 
 > 
 > Ah sorry, it's unprivileged-user.

 Got it.

 > > IMHO, we should only document in tests(7) the configuration variables
 > > which are not part of ATF.
 > 
 > Well, I guess this one is a bit of a compromise.  unprivileged-user
 > was _not_ an atf-specific variable; it used to be defined by NetBSD
 > only.  These days, it has a special meaning in atf itself, but some
 > NetBSD tests query it directly to do their own stuff.  In other
 > words, it is not only used by require.user=unprivileged, but also to
 > perform some specific actions in the tmpfs tests.

 I'll have a look, and add it.

 -- 
 Nicolas Joly

 Projects and Developments in Bioinformatics
 Institut Pasteur, Paris.

From: Nicolas Joly <njoly@pasteur.fr>
To: Julio Merino <jmmv@NetBSD.org>
Cc: Nicolas Joly <njoly@pasteur.fr>, gnats-bugs@NetBSD.org,
	misc-bug-people@netbsd.org, gnats-admin@netbsd.org,
	netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 23:24:26 +0200

 --vkogqOf2sHV7VnPd
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline

 On Thu, Jun 16, 2011 at 05:12:52PM +0200, Nicolas Joly wrote:
 > On Thu, Jun 16, 2011 at 04:01:12PM +0100, Julio M. Merino Vidal wrote:
 > > On 6/16/11 3:52 PM, Nicolas Joly wrote:
 > > > On Thu, Jun 16, 2011 at 02:44:21PM +0100, Julio M. Merino Vidal wrote:
 > > >>
 > > >> Also document the unprivileged_user option.  It's used explicitly by
 > > >> some tests.  (It defaults to _atf.)
 > > > 
 > > > I don't find it anywhere. Is it "require.user" = "unprivileged" ? 
 > > 
 > > Ah sorry, it's unprivileged-user.
 > 
 > Got it.
 > 
 > > > IMHO, we should only document in tests(7) the configuration variables
 > > > which are not part of ATF.
 > > 
 > > Well, I guess this one is a bit of a compromise.  unprivileged-user
 > > was _not_ an atf-specific variable; it used to be defined by NetBSD
 > > only.  These days, it has a special meaning in atf itself, but some
 > > NetBSD tests query it directly to do their own stuff.  In other
 > > words, it is not only used by require.user=unprivileged, but also to
 > > perform some specific actions in the tmpfs tests.
 > 
 > I'll have a look, and add it.

 Julio,

 Is the `unprivileged-user' option description correct ?

 Thanks.

 -- 
 Nicolas Joly

 Projects and Developments in Bioinformatics
 Institut Pasteur, Paris.

 --vkogqOf2sHV7VnPd
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: attachment; filename="netbsd-testsman.diff"

 Index: share/man/man7/tests.7
 ===================================================================
 RCS file: /cvsroot/src/share/man/man7/tests.7,v
 retrieving revision 1.4
 diff -u -p -r1.4 tests.7
 --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 +++ share/man/man7/tests.7	16 Jun 2011 21:08:04 -0000
 @@ -25,7 +25,7 @@
  .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
  .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  .\"
 -.Dd November 7, 2010
 +.Dd June 16, 2011
  .Dt TESTS 7
  .Os
  .Sh NAME
 @@ -163,6 +163,20 @@ The suite-specific configuration file im
  which contains properties shared among all test suites.
  These files conform to the configuration file format described in
  .Xr atf-formats 5 .
 +.Pp
 +The following configuration variables are available in the
 +.Nx
 +test suite :
 +.Bl -tag -width "unprivileged-user"
 +.It fstype
 +When set to a filesystem type, restrict tests programs from the
 +.Pa /usr/tests/fs/vfs/
 +tree to only run test cases for the given type.
 +.It unprivileged-user
 +This variable allows setting an unprivileged user login name to be used by
 +tests. Default to
 +.Sq _atf .
 +.El
  .Ss What to do if something fails?
  If there is
  .Em any failure

 --vkogqOf2sHV7VnPd--

From: Julio Merino <jmmv@NetBSD.org>
To: Nicolas Joly <njoly@pasteur.fr>
Cc: gnats-bugs@NetBSD.org, misc-bug-people@netbsd.org, 
 gnats-admin@netbsd.org, netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Thu, 16 Jun 2011 22:29:01 +0100

 On 6/16/11 10:24 PM, Nicolas Joly wrote:
 > Julio,
 >
 > Is the `unprivileged-user' option description correct ?

 Yup; see below.

 > netbsd-testsman.diff
 >
 >
 > Index: share/man/man7/tests.7
 > ===================================================================
 > RCS file: /cvsroot/src/share/man/man7/tests.7,v
 > retrieving revision 1.4
 > diff -u -p -r1.4 tests.7
 > --- share/man/man7/tests.7	7 Nov 2010 17:49:33 -0000	1.4
 > +++ share/man/man7/tests.7	16 Jun 2011 21:08:04 -0000
 > @@ -25,7 +25,7 @@
 >   .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 >   .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 >   .\"
 > -.Dd November 7, 2010
 > +.Dd June 16, 2011
 >   .Dt TESTS 7
 >   .Os
 >   .Sh NAME
 > @@ -163,6 +163,20 @@ The suite-specific configuration file im
 >   which contains properties shared among all test suites.
 >   These files conform to the configuration file format described in
 >   .Xr atf-formats 5 .
 > +.Pp
 > +The following configuration variables are available in the
 > +.Nx
 > +test suite :

 The space before : is probably not desired.

 > +.Bl -tag -width "unprivileged-user"
 > +.It fstype
 > +When set to a filesystem type, restrict tests programs from the
 > +.Pa/usr/tests/fs/vfs/
 > +tree to only run test cases for the given type.
 > +.It unprivileged-user
 > +This variable allows setting an unprivileged user login name to be used by
 > +tests. Default to

 "Defaults to".  Also, new sentence new line.

 > +.Sq _atf .
 > +.El
 >   .Ss What to do if something fails?
 >   If there is
 >   .Em any failure

 Thanks for doing this!

 -- 
 Julio Merino / @jmmv

From: "Nicolas Joly" <njoly@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/45038 CVS commit: src/share/man/man7
Date: Thu, 16 Jun 2011 21:42:38 +0000

 Module Name:	src
 Committed By:	njoly
 Date:		Thu Jun 16 21:42:38 UTC 2011

 Modified Files:
 	src/share/man/man7: tests.7

 Log Message:
 Add fstype and unprivileged-user tests configuration variables
 description. Fix PR/45038.


 To generate a diff of this commit:
 cvs rdiff -u -r1.4 -r1.5 src/share/man/man7/tests.7

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

Responsible-Changed-From-To: misc-bug-people->njoly
Responsible-Changed-By: njoly@NetBSD.org
Responsible-Changed-When: Thu, 16 Jun 2011 21:49:19 +0000
Responsible-Changed-Why:
take


State-Changed-From-To: open->feedback
State-Changed-By: njoly@NetBSD.org
State-Changed-When: Thu, 16 Jun 2011 21:49:19 +0000
State-Changed-Why:
I added the tests configurations variables descriptions.
Does this looks ok ?


From: yamt@mwd.biglobe.ne.jp (YAMAMOTO Takashi)
To: gnats-bugs@NetBSD.org
Cc: misc-bug-people@netbsd.org, gnats-admin@netbsd.org,
	netbsd-bugs@netbsd.org, yamt@NetBSD.org
Subject: Re: misc/45038: lack of tests options
Date: Fri, 17 Jun 2011 00:37:03 +0000 (UTC)

 >  > >Description:
 >  > 	i always fail to remember the fstype= option in the following.
 >  > 
 >  > 		cd /usr/tests/fs/vfs; atf-run -v fstype=nfs|atf-report
 >  > 
 >  > 	probably options like this should be documented in tests(7)?
 >  
 >  Hi,
 >  
 >  Does the following patch fit your needs ?

 sure, it's exactly what i wanted to see.  thanks.

 YAMAMOTO Takashi

State-Changed-From-To: feedback->closed
State-Changed-By: njoly@NetBSD.org
State-Changed-When: Fri, 17 Jun 2011 08:44:07 +0000
State-Changed-Why:
Submitter is happy with the change.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.