From pgilbert902 at gmail.com  Thu Nov 27 17:23:34 2014
From: pgilbert902 at gmail.com (Paul Gilbert)
Date: Thu, 27 Nov 2014 11:23:34 -0500
Subject: [Rd] testing dontrun  examples
In-Reply-To: <5476590E.1040804@gmail.com>
References: <54761FC6.3090007@gmail.com> <5476590E.1040804@gmail.com>
Message-ID: <54775006.5000101@gmail.com>



On 14-11-26 05:49 PM, Duncan Murdoch wrote:
> On 26/11/2014, 1:45 PM, Paul Gilbert wrote:
>> Is there a good strategy for testing examples which should not be run by
>> default? For instance, I have examples which get data from the Internet.
>> If I wrap them in try() then they can be skipped if the Internet is not
>> available, but may not be tested in cases when I would like to know
>> about the failure. (Not to mention that the example syntax is ugly.)
>>
>> If I mark them \dontrun or \donttest then they are not tested. I could
>> mark them \dontrun and then use example() but for this, in addition to
>> run.dontrun=TRUE, I would need to specify all topics for a package, and
>> I don't see how to do this, missing topic does not work.
>>
>> Wishlist: what I would really like is R CMD check --run-dontrun   pkg
>
>
> We have that in R-devel, so everyone will have it next April, but there
> will possibly be bugs unless people like you try it out now.

Are you anticipating my wishes now, or did you tell me this and it 
entered my subconscious? So far it works as advertised.

Thanks,
Paul
>
> Duncan Murdoch
>



[Rd] testing dontrun examples
Paul Gilbert