Skip to content

Commit

Permalink
Update test-encoding.R: Fix test on FreeBSD
Browse files Browse the repository at this point in the history
Under FreeBSD test fails because it only skips linux, mac and solaris.
Opimize logic and use this test only on windows.

Fixes r-dbi/RSQLite#502
  • Loading branch information
nunotexbsd authored and bpvgoncalves committed Apr 10, 2024
1 parent da0771e commit e5fffbf
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions tests/testthat/test-encoding.R
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@ test_that("write tables whose colnames and contents are UTF-8 encoded (#277)", {
})

test_that("list the field of tables whose colnames are BIG5 encoded (#277)", {
skip_on_os("linux")
skip_on_os("mac")
skip_on_os("solaris")
skip_if_not(.Platform$OS.type == "windows")
if (.Platform$OS.type == "windows") {
withr::local_collate("cht")
} else {
Expand Down Expand Up @@ -133,9 +131,7 @@ test_that("append tables whose colnames are UTF-8 encoded (#277)", {
})

test_that("write tables whose colnames or contents are BIG5 encoded (#277)", {
skip_on_os("linux")
skip_on_os("mac")
skip_on_os("solaris")
skip_if_not(.Platform$OS.type == "windows")

.loc <- Sys.getlocale("LC_COLLATE")
suppressWarnings(Sys.setlocale(locale = "cht"))
Expand Down

0 comments on commit e5fffbf

Please sign in to comment.