Skip to content

Commit 86d1cd1

Browse files
committed
capital B
- Use `B` instead of `b` as unit.
1 parent 684c0ed commit 86d1cd1

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

R/format.R

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ is_vector_s3.blob <- function(x) TRUE
3434
blob_size <- function(x, digits = 3, trim = TRUE, ...) {
3535
x <- vapply(x, length, numeric(1))
3636

37-
units <- c("kb", "Mb", "Gb", "Tb")
37+
units <- c("kB", "MB", "GB", "TB")
3838
power <- min(floor(log(abs(x), 1000)), length(units))
3939
if (power < 1) {
4040
unit <- "B"

tests/testthat/test-format.R

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,9 @@ test_that("similar sizes", {
3535
expect_format_equal(
3636
format(x),
3737
c(
38-
"blob[1 kb]",
39-
"blob[2 kb]",
40-
"blob[4 kb]"
38+
"blob[1 kB]",
39+
"blob[2 kB]",
40+
"blob[4 kB]"
4141
)
4242
)
4343
})

0 commit comments

Comments
 (0)