Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit9d95620

Browse files
authored
Update to testthat 3e (#26)
1 parentc0a6149 commit9d95620

File tree

8 files changed

+14
-14
lines changed

8 files changed

+14
-14
lines changed

‎DESCRIPTION‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,10 @@ Suggests:
2929
rlog,
3030
rmarkdown,
3131
rsyslog,
32-
testthat
32+
testthat (>= 3.0.0)
3333
Encoding: UTF-8
3434
LazyLoad: yes
3535
Roxygen: list(old_usage = TRUE)
3636
RoxygenNote: 7.3.2
3737
VignetteBuilder: knitr
38+
Config/testthat/edition: 3

‎tests/run-all.R‎

Lines changed: 0 additions & 3 deletions
This file was deleted.

‎tests/testthat.R‎

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# This file is part of the standard setup for testthat.
2+
# It is recommended that you do not modify it.
3+
#
4+
# Where should you do additional test configuration?
5+
# Learn more about the roles of various files in:
6+
# * https://r-pkgs.org/tests.html
7+
# * https://testthat.r-lib.org/reference/test_package.html#special-files
8+
9+
library(testthat)
10+
library(log4r)
11+
12+
test_check("log4r")

‎tests/testthat/test-acceptance.R‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
context("acceptance")
2-
31
test_that('Creation', {
42
logger<- create.logger()
53
expect_s3_class(logger,"logger")

‎tests/testthat/test-appenders.R‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
context("appenders")
2-
31
test_that("The console appender works correctly", {
42
appender<- console_appender(simple_log_layout())
53
expect_output(appender("Message"),"Message")

‎tests/testthat/test-layouts.R‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
context("layouts")
2-
31
test_that("Basic layouts work correctly", {
42
layout<- simple_log_layout()
53
expect_match(layout("INFO","Message"),"Message")

‎tests/testthat/test-loglevel.R‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
context("loglevel")
2-
31
test_that("The loglevel() constructor works as expected", {
42
expect_equal(loglevel(-19),DEBUG)
53
expect_equal(loglevel(-1),DEBUG)

‎tests/testthat/test-verbosity.R‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
context("verbosity")
2-
31
test_that("The verbosity() constructor creates equivalent log levels", {
42
expect_equal(verbosity(-19), FATAL)
53
expect_equal(verbosity(-1), FATAL)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp