MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / check_variant

Function check_variant

atomic-cli/src/commands/vault/mod.rs:264–278  ·  view source on GitHub ↗

Ensure all variants exist and can be matched

(cmd: &VaultCommands)

Source from the content-addressed store, hash-verified

262 fn test_vault_commands_variants() {
263 // Ensure all variants exist and can be matched
264 fn check_variant(cmd: &VaultCommands) -> &'static str {
265 match cmd {
266 VaultCommands::Init(_) => "init",
267 VaultCommands::Show(_) => "show",
268 VaultCommands::List(_) => "list",
269 VaultCommands::Materialize(_) => "materialize",
270 VaultCommands::Sync(_) => "sync",
271 VaultCommands::Goal(_) => "goal",
272 VaultCommands::Intent(_) => "intent",
273 VaultCommands::Memory(_) => "memory",
274 VaultCommands::Context(_) => "context",
275 VaultCommands::Summaries(_) => "summaries",
276 VaultCommands::Query(_) => "query",
277 }
278 }
279
280 // Verify variant name extraction works for each variant name string
281 let names = [

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected