diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-24 12:56:51 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2026-02-24 12:56:51 +0000 |
| commit | ef279a881fc1694fe2d868a32224874eb50cd358 (patch) | |
| tree | e3b3ec420aecf9c6e5d56cb77fcbcc5d1b8c9481 /grasp-audit | |
| parent | 3f4dc8e1bc07f88c064d4734f5cc3ee87b1497e4 (diff) | |
wire PurgatoryTests into CLI runner so purgatory tests are actually run
Diffstat (limited to 'grasp-audit')
| -rw-r--r-- | grasp-audit/src/bin/grasp-audit.rs | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/grasp-audit/src/bin/grasp-audit.rs b/grasp-audit/src/bin/grasp-audit.rs index 99e3c35..b3fa0db 100644 --- a/grasp-audit/src/bin/grasp-audit.rs +++ b/grasp-audit/src/bin/grasp-audit.rs | |||
| @@ -27,7 +27,7 @@ enum Commands { | |||
| 27 | #[arg(short, long, default_value = "shared")] | 27 | #[arg(short, long, default_value = "shared")] |
| 28 | mode: String, | 28 | mode: String, |
| 29 | 29 | ||
| 30 | /// Spec to test (nip01-smoke, nip11, event-acceptance, cors, git-clone, git-filter, push-auth, repo-creation, all) | 30 | /// Spec to test (nip01-smoke, nip11, event-acceptance, cors, git-clone, git-filter, push-auth, repo-creation, purgatory, all) |
| 31 | #[arg(short, long, default_value = "all")] | 31 | #[arg(short, long, default_value = "all")] |
| 32 | spec: String, | 32 | spec: String, |
| 33 | 33 | ||
| @@ -136,6 +136,10 @@ async fn main() -> Result<()> { | |||
| 136 | println!("Running repository creation tests...\n"); | 136 | println!("Running repository creation tests...\n"); |
| 137 | specs::RepositoryCreationTests::run_all(&client, &relay_domain).await | 137 | specs::RepositoryCreationTests::run_all(&client, &relay_domain).await |
| 138 | } | 138 | } |
| 139 | "purgatory" => { | ||
| 140 | println!("Running purgatory tests...\n"); | ||
| 141 | specs::PurgatoryTests::run_all(&client).await | ||
| 142 | } | ||
| 139 | "all" => { | 143 | "all" => { |
| 140 | println!("Running all tests...\n"); | 144 | println!("Running all tests...\n"); |
| 141 | let mut all_results = AuditResult::new("All GRASP-01 Tests"); | 145 | let mut all_results = AuditResult::new("All GRASP-01 Tests"); |
| @@ -180,12 +184,17 @@ async fn main() -> Result<()> { | |||
| 180 | let cors_results = specs::CorsTests::run_all(&client, &relay_domain).await; | 184 | let cors_results = specs::CorsTests::run_all(&client, &relay_domain).await; |
| 181 | all_results.merge(cors_results); | 185 | all_results.merge(cors_results); |
| 182 | 186 | ||
| 187 | // Purgatory tests | ||
| 188 | println!(" → Purgatory tests..."); | ||
| 189 | let purgatory_results = specs::PurgatoryTests::run_all(&client).await; | ||
| 190 | all_results.merge(purgatory_results); | ||
| 191 | |||
| 183 | println!(); | 192 | println!(); |
| 184 | all_results | 193 | all_results |
| 185 | } | 194 | } |
| 186 | _ => { | 195 | _ => { |
| 187 | return Err(anyhow!( | 196 | return Err(anyhow!( |
| 188 | "Unknown spec: {}. Use 'nip01-smoke', 'nip11', 'event-acceptance', 'cors', 'git-clone', 'git-filter', 'push-auth', 'repo-creation', or 'all'", | 197 | "Unknown spec: {}. Use 'nip01-smoke', 'nip11', 'event-acceptance', 'cors', 'git-clone', 'git-filter', 'push-auth', 'repo-creation', 'purgatory', or 'all'", |
| 189 | spec | 198 | spec |
| 190 | )) | 199 | )) |
| 191 | } | 200 | } |