Skip to content

Commit 071970b

Browse files
committed
lints
1 parent 6255414 commit 071970b

File tree

2 files changed

+20
-19
lines changed

2 files changed

+20
-19
lines changed

R/app-driver-expect-screenshot.R

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -132,26 +132,26 @@ app_expect_screenshot <- function(
132132
)
133133
}
134134

135-
app_expect_screenshot_and_variant <- function(
136-
# nolint
137-
self,
138-
private,
139-
...
140-
) {
141-
if (app_is_missing_variant(self, private)) {
142-
app_abort(
143-
self,
144-
private,
145-
c(
146-
"This `AppDriver` object can not call `$expect_screenshot()` without a `variant` initialized. Please supply a `variant` value when creating your `AppDriver` object, like `AppDriver(variant = <value>)`",
147-
i = "`variant = platform_variant()` is the suggested value",
148-
i = "`variant = NULL` can work, but screenshots are known to cause conflicts when changing R version or platform."
135+
app_expect_screenshot_and_variant <- # nolint
136+
function(
137+
self,
138+
private,
139+
...
140+
) {
141+
if (app_is_missing_variant(self, private)) {
142+
app_abort(
143+
self,
144+
private,
145+
c(
146+
"This `AppDriver` object can not call `$expect_screenshot()` without a `variant` initialized. Please supply a `variant` value when creating your `AppDriver` object, like `AppDriver(variant = <value>)`",
147+
i = "`variant = platform_variant()` is the suggested value",
148+
i = "`variant = NULL` can work, but screenshots are known to cause conflicts when changing R version or platform."
149+
)
149150
)
150-
)
151+
}
152+
# Expect screenshot
153+
app_expect_screenshot(self, private, ...)
151154
}
152-
# Expect screenshot
153-
app_expect_screenshot(self, private, ...)
154-
}
155155

156156

157157
handle_custom_selector <- function(self, private, screenshot_args) {

R/app-driver.R

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,8 +202,9 @@ check_cran_deprecated <- function(
202202
#' @importFrom R6 R6Class
203203
#' @seealso [`platform_variant()`], [`use_shinytest2_test()`]
204204
#' @export
205+
# nolint start
205206
AppDriver <- R6Class(
206-
# nolint
207+
# nolint end
207208
"AppDriver",
208209
cloneable = FALSE,
209210
private = list(

0 commit comments

Comments
 (0)