Skip to content

Commit

Permalink
Add header tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jonclayden committed Feb 14, 2024
1 parent ab53adb commit 43963b2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/testthat/test-05-nifti.R
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ test_that("NIfTI files can be read and written", {

expect_output(print(niftiHeader(image)), "NIfTI-1 header")
expect_equal(image$bitpix, 32L)
expect_null(image$glmax)
expect_equal(niftiHeader(imagePath,unused=TRUE)$glmax, 0L)
expect_equal(analyzeHeader(imagePath)$datatype, 4L)
writeNifti(image, tempPath, datatype="short")
expect_equal(niftiHeader(tempPath)$bitpix, 16L)
unlink(tempPath)
Expand Down

0 comments on commit 43963b2

Please sign in to comment.