Skip to content

Commit

Permalink
tests: test all config files in config subdirectory
Browse files Browse the repository at this point in the history
Signed-off-by: simonsan <[email protected]>
  • Loading branch information
simonsan committed Feb 11, 2024
1 parent 9b7edb5 commit 586e0f0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ use std::{fs, path::PathBuf};

/// Ensure all `configs` parse as a valid config files
#[rstest]
fn test_parse_rustic_configs_is_ok(#[files("config/*.toml")] config_path: PathBuf) -> Result<()> {
fn test_parse_rustic_configs_is_ok(
#[files("config/**/*.toml")] config_path: PathBuf,
) -> Result<()> {
let toml_string = fs::read_to_string(config_path)?;
let _ = toml::from_str::<RusticConfig>(&toml_string)?;

Expand Down

0 comments on commit 586e0f0

Please sign in to comment.