similar to: Using unit-tests as examples

Displaying 20 results from an estimated 9000 matches similar to: "Using unit-tests as examples"

2014 Jul 25
1
[Wishlist] a 'PackageDevelopment' Task View
Hello everybody, as a young/unexperienced R package developer (only a few, mainly for personal use) i was thinking it could be very useful having a "meta" task view for all package-development related packages and/or function. Something like ... Creation - utils::package.skeleton, pkgKitten, Rcpp::Rcpp.package.skeleton Foreign languages interfaces: - Rcpp Documentation - roxygen2
2012 May 17
2
test suites for packages
Can anyone share some opinions on test suites for R packages? I'm looking at testthat and RUnit. Does anyone have strong opinions on either of those. Any additional packages I should consider? Thanks, Whit
2014 Jan 22
1
Behavior of --install-tests and testInstalledPackage
Hello, I'm writing a script that automates the testing of reverse dependencies of a package. I found the function testInstalledPackage in the tools package, which seems to do what I want. However, when I use it for a source package that was installed with --install-tests, I've noticed that only the actual test files (e.g. located in inst/tests) are available and run. In other words the
2015 Jan 22
5
Programming Tools CTV
I've had a lot of requests for additions to the reproducible research task view that fall into a grey area (to me at least). For example, roxygen2 is a tool that broadly enable reproducibility but I see it more as a tool for better programming. I'm about to check in a new version of the task view that includes packrat and checkpoint, as they seem closer to reproducible research, but also
2015 Apr 19
4
running unit tests on the stringr package
I am trying to learn how to run the unit tests in the stringr package and have the following questions. 1) The r-cran-stringr package does not suggest/depend on the r-cran-testthat package . Would it make sense to add such a thing since after all the tests in /usr/lib/R/site-library/stringr/tests rely on testthat package? 2) I am getting the following error when trying to run the unit tests %
2018 Sep 18
2
Suggested Patch: Adding commas to list of packages after R CMD check
Dear R-devs, Scenario: When checking a package via `R CMD check package_tar.ball`, required / suggested packages may be missing. R subsequently returns a list of packages that are missing (delimited by spaces). Example: ``` R CMD check glmSparseNet_0.99.13.tar.gz * using log directory '/home/ubuntu/Bioconductor/glmSparseNet.Rcheck' * using R Under development (unstable) (2018-06-06
2007 May 09
4
Unit Testing Frameworks: summary and brief discussion
Greetings - I'm finally finished review, here's what I heard: ============ from Tobias Verbeke: anthony.rossini@novartis.com wrote: > Greetings! > > After a quick look at current programming tools, especially with regards > to unit-testing frameworks, I've started looking at both "butler" and > "RUnit". I would be grateful to receieve real
2009 Oct 05
3
unit testing for R packages?
Hi All, I'm interested in putting some unit tests into an R package I'm building. I have seen assorted things such as Runit library, svUnit library, packages with 'tests' directories, etc I grep'd "unit test" through the writing R extensions manual but didn't find anything. Are there any suggestions out there? Currently I have several (a lot?) classes/methods
2011 Mar 31
0
Is it possible to run unit tests after a package installation?
Dear all, I'm deep into Chambers' SoDA and R-exts.html but I can't find all answers. The thing is that I would like to run my unit tests right after a package installation. That is while the command "R CMD check <package_name>" runs all files named <package_name>/tests/*.R (so unit tests can be placed there) I wonder if it is possible to run them on some
2023 Mar 01
1
Incorrect behavior of ks.test and psmirnov functions with exact=TRUE
HI, I've noticed what I think is an incorrect behavior of stats::psmirnov function and consequently of ks.test when run in an exact mode. For example: psmirnov(1, sizes=c(50, 50), z=1:100, two.sided = FALSE, lower.tail = F, exact=TRUE) produces 2.775558e-15 However, the exact value should be 1/combination(100, 50), which is 9.9e-30. While the absolute error is small, the relative error is
2015 Jan 22
2
Programming Tools CTV
On Thu, Jan 22, 2015 at 12:45 PM, Achim Zeileis <Achim.Zeileis at uibk.ac.at> wrote: > On Thu, 22 Jan 2015, Max Kuhn wrote: > >> I've had a lot of requests for additions to the reproducible research >> task view that fall into a grey area (to me at least). >> >> For example, roxygen2 is a tool that broadly enable reproducibility >> but I see it more as
2017 Sep 17
2
R-devel r73293 and the testthat package
Hello, Windows R-devel no longer lets me use testthat even though the CRAN checks are pretty much clean. I have copied my session output below. Will R Under development (unstable) (2017-09-16 r73293) -- "Unsuffered Consequences" Copyright (C) 2017 The R Foundation for Statistical Computing Platform: x86_64-w64-mingw32/x64 (64-bit) R is free software and comes with ABSOLUTELY NO
2006 Mar 18
2
ANN: capistrano-runit-tasks 0.1.0
I''d like to announce the first release of capistrano-runit-tasks. This came about as I wanted to use runit rather than spinner/spawner/ reaper on my memory limited VPS but should be useable for any setup. From the README: This library extends Capistrano to allow processes to be supervised using the runit package. It replaces some of the standard tasks with runit versions and
2023 Jan 10
1
rhub vs. CRAN fedora-*-devel, using armadillo & slapack
On 10/01/2023 4:07 p.m., Sebastian Meyer wrote: > Am 10.01.23 um 21:28 schrieb Duncan Murdoch: >> On 10/01/2023 2:05 p.m., Ivan Krylov wrote: >>> On Tue, 10 Jan 2023 16:27:53 +0000 >>> RICHET Yann <yann.richet at irsn.fr> wrote: >>> >>>> In facts, 10 threads are asked by armadillo for some LinAlg, which >>>> backs to two threads as
2023 Jan 11
2
rhub vs. CRAN fedora-*-devel, using armadillo & slapack
Thank you all, for these advices. So I try to fix OMP_THREADS, cleanup tests, and display explicitly what test is running by moving in tests/ instead of tests/testthat/... Next step should be to investigate blocking test using a reporter (maybe "list"). For now, waiting for CRAN results... Yann -----Message d'origine----- De?: Duncan Murdoch <murdoch.duncan at gmail.com>
2015 May 04
2
Print output during long tests?
I am the author of R package animint which uses testthat for unit tests. This means that there is a single test file (animint/tests/testthat.R) and during R CMD check we will see the following output * checking tests ... Running ?testthat.R? I run these tests on Travis, which has a policy that if no output is received after 10 minutes, it will kill the check. Because animint's testthat
2023 Jan 10
1
rhub vs. CRAN fedora-*-devel, using armadillo & slapack
Am 10.01.23 um 21:28 schrieb Duncan Murdoch: > On 10/01/2023 2:05 p.m., Ivan Krylov wrote: >> On Tue, 10 Jan 2023 16:27:53 +0000 >> RICHET Yann <yann.richet at irsn.fr> wrote: >> >>> In facts, 10 threads are asked by armadillo for some LinAlg, which >>> backs to two threads as warned. >> >> I think you're right about your tests de-facto
2015 Feb 08
1
Testthat and global environments in R packages on CRAN
Hi! The problem is that the test environment inherits from the global environment. See https://github.com/hadley/testthat/blob/master/R/test-files.r The students labs are simply an R script file. Say that they have an assignment to calculate sqrt(2) and store it in variable a. In the same session they should be able to test the script file when they are done (using a function mark_my_file() in
2016 Feb 11
2
inconsistency in treatment of USE.NAMES argument
Changing the vapply() behavior makes sense in principle. I analyzed the CRAN code base using the R parser and found 143 instances of calling vapply with USE.NAMES=FALSE. These would need to be inspected to understand the consequences of the change. For reference: /AzureML/R/datasets.R:226 /BBmisc/R/toRangeStr.R:33 /DBI/R/DBDriver.R:205 /Kmisc/R/str_rev.R:37 /Matrix/R/diagMatrix.R:98
2010 Nov 15
2
Trying to understand the search path and namespaces
Hi all, I'm trying to understand how the search path and namespaces interact. For example, take the devtools package which suggests the testthat package. Here's what the search path looks like after I load each of those packages: > library(devtools) > search() [1] ".GlobalEnv" "package:devtools" "package:stats" [4]