tests/testthat/test_str.R

library(ribiosUtils)

expect_identical(ribiosUtils:::shortenStr("ETV"), "ETV")
expect_identical(ribiosUtils:::shortenStr("abcdefgh"), "abcdefgh")
expect_identical(ribiosUtils:::shortenStr("abcdefghijkl"), "abcdefgh...")

expect_identical(ribiosUtils:::fixWidthStr("ETV"), "ETV     ")
expect_identical(ribiosUtils:::fixWidthStr("abcdefgh"), "abcdefgh")
expect_identical(ribiosUtils:::fixWidthStr("abcdefghijkl"),
                 "abcde...")

Try the ribiosUtils package in your browser

Any scripts or data that you put into this service are public.

ribiosUtils documentation built on March 13, 2020, 2:54 a.m.