From 15593204e0241c4c142800ea079c28214214809b Mon Sep 17 00:00:00 2001 From: Robert Garrett Date: Thu, 17 Jul 2025 10:28:17 -0500 Subject: [PATCH] Put the per-project test expects in for lconf() Put all those per-project configs into the unit test. They're in the input string, so we should expect to see them in the output struct. --- src/config.rs | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) diff --git a/src/config.rs b/src/config.rs index 988101a..508768a 100644 --- a/src/config.rs +++ b/src/config.rs @@ -174,7 +174,30 @@ repo = \"rcalc\" repo: None, token: Some(String::from("fake-token")) }, - project_overrides: vec![], + project_overrides: vec![ + PartialConfig { + project_path: Some(String::from("/home/robert/projects/gt-tool")), + gitea_url: None, + owner: Some(String::from("robert")), + repo: Some(String::from("gt-tool")), + token: None, + }, + PartialConfig { + project_path: Some(String::from("/home/robert/projects/rcalc")), + gitea_url: None, + owner: Some(String::from("jamis")), + repo: Some(String::from("rcalc")), + token: None, + }, + PartialConfig { + project_path: Some(String::from("/home/robert/projects/rcalc-builders")), + gitea_url: None, + owner: Some(String::from("jamis")), + repo: Some(String::from("rcalc")), + token: None, + }, + + ], }; let conf = lconf(fx_sample_config_string)?; println!(" ->> Test conf: {:?}", conf);