Skip to content

Commit

Permalink
test if args from config.json are overridden
Browse files Browse the repository at this point in the history
  • Loading branch information
ducaale committed Aug 2, 2021
1 parent f85c2cd commit aee1a42
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/cli.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1330,15 +1330,15 @@ fn read_args_from_config() {
File::create(config_dir.path().join("config.json")).unwrap();
std::fs::write(
config_dir.path().join("config.json"),
serde_json::json!({"default_options": ["--form"]}).to_string(),
serde_json::json!({"default_options": ["--form", "--print=hbHB"]}).to_string(),
)
.unwrap();

get_command()
.env("XH_CONFIG_DIR", config_dir.path())
.arg(":")
.arg("--offline")
.arg("--print=B")
.arg("--print=B") // this should overwrite the value from config.json
.arg("sort=asc")
.arg("limit=100")
.assert()
Expand Down

0 comments on commit aee1a42

Please sign in to comment.