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

Function view_flag_is_removed

atomic-cli/tests/it/restore_integration_test.rs:196–209  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

194
195#[test]
196fn view_flag_is_removed() {
197 // `--view` was removed; switching views is `atomic view switch`. clap
198 // should reject the unknown flag before any work happens.
199 let dir = repo_with_recorded_file();
200 let root = dir.path();
201
202 let out = atomic(root, &["restore", "--view", "feature", "--force"]);
203 assert!(!out.status.success(), "--view should no longer be accepted");
204 let stderr = String::from_utf8_lossy(&out.stderr);
205 assert!(
206 stderr.contains("unexpected argument") || stderr.contains("--view"),
207 "clap should reject --view, got: {stderr}"
208 );
209}
210
211#[test]
212fn view_flag_is_removed_for_reset_alias_too() {

Callers

nothing calls this directly

Calls 3

repo_with_recorded_fileFunction · 0.70
atomicFunction · 0.70
pathMethod · 0.45

Tested by

no test coverage detected