# Generated by roxytest: Do not edit by hand!
# File R/export.R: @tests
test_that("Function write_gedcom() @ L24", {
expect_error(write_gedcom(read_gedcom(system.file("extdata", "555SAMPLE.GED", package = "tidyged.io")),
"my_family.txt"))
file.remove("my_family.txt")
expect_identical(
read_gedcom(system.file("extdata", "555SAMPLE.GED", package = "tidyged.io")),
read_gedcom(system.file("extdata", "555SAMPLE.GED", package = "tidyged.io")) |>
write_gedcom("555Sample.ged") |>
read_gedcom()
)
file.remove("555Sample.ged")
})
test_that("Function update_header_with_filename() @ L74", {
expect_snapshot_value(read_gedcom(system.file("extdata", "555SAMPLE.GED", package = "tidyged.io")) |>
update_header_with_filename("my_file.ged"), "json2")
expect_snapshot_value(read_gedcom(system.file("extdata", "MINIMAL555.GED", package = "tidyged.io")) |>
update_header_with_filename("my_file2.ged"), "json2")
})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.