@@ -13,7 +13,7 @@ test_that("position_dodge is translated to barmode=group", {
13
13
L <- gg2list(gg.dodge )
14
14
expect_equal(length(L ), 3 )
15
15
trace.names <- sapply(L [1 : 2 ], " [[" , " name" )
16
- stopifnot( c(" Math" , " Bio" ) %in% trace.names )
16
+ expect_true(all( c(" Math" , " Bio" ) %in% trace.names ) )
17
17
expect_identical(L $ kwargs $ layout $ barmode , " group" )
18
18
})
19
19
@@ -22,7 +22,7 @@ test_that("position_stack is translated to barmode=stack", {
22
22
gg2list(gg.stack )
23
23
expect_equal(length(L ), 3 )
24
24
trace.names <- sapply(L [1 : 2 ], " [[" , " name" )
25
- stopifnot( c(" Math" , " Bio" ) %in% trace.names )
25
+ expect_true(all( c(" Math" , " Bio" ) %in% trace.names ) )
26
26
expect_identical(L $ kwargs $ layout $ barmode , " stack" )
27
27
})
28
28
@@ -31,7 +31,7 @@ test_that("position_identity is translated to barmode=overlay", {
31
31
gg2list(gg.identity )
32
32
expect_equal(length(L ), 3 )
33
33
trace.names <- sapply(L [1 : 2 ], " [[" , " name" )
34
- stopifnot( c(" Math" , " Bio" ) %in% trace.names )
34
+ expect_true(all( c(" Math" , " Bio" ) %in% trace.names ) )
35
35
expect_identical(L $ kwargs $ layout $ barmode , " overlay" )
36
36
})
37
37
0 commit comments