Skip to content

Commit

Permalink
Minor change
Browse files Browse the repository at this point in the history
  • Loading branch information
grimbough committed Mar 11, 2024
1 parent 6f12f87 commit 13a34f4
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions tests/testthat/test_roundtrip.R
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@
## Current caveat is that we typically return an array even when there is only
## one dimension.

library(rhdf5)

h5file <- tempfile(pattern = "h5_roundtrip_", fileext = ".h5")

test_that("data.frame columns survive a round trip", {
Expand Down Expand Up @@ -58,6 +60,8 @@ test_that("UTF-8 strings are preserved", {
})

test_that("Complex numbers are writen to a compound datatype", {

h5file <- tempfile(pattern = "h5_roundtrip_", fileext = ".h5")

mat <- matrix(complex(length.out = 30, real = 1:30, imaginary = 30:1), ncol = 10)
expect_silent(h5write(obj = mat, file = h5file, name = 'complex'))
Expand Down

0 comments on commit 13a34f4

Please sign in to comment.