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

Function test_remote_config_add_duplicate

atomic-repository/src/remote.rs:788–796  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

786
787 #[test]
788 fn test_remote_config_add_duplicate() {
789 let mut config = RemoteConfig::new();
790 config
791 .add("origin", RemoteEntry::new("https://example.com/repo"))
792 .unwrap();
793
794 let result = config.add("origin", RemoteEntry::new("https://other.com/repo"));
795 assert!(matches!(result, Err(RemoteError::AlreadyExists { .. })));
796 }
797
798 #[test]
799 fn test_remote_config_add_invalid_name() {

Callers

nothing calls this directly

Calls 2

unwrapMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected