MCPcopy Create free account
hub / github.com/calfonso/rusternetes / test_json_patch_remove

Function test_json_patch_remove

crates/api-server/src/patch.rs:699–711  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

697
698 #[test]
699 fn test_json_patch_remove() {
700 let original = json!({
701 "name": "test",
702 "value": 42
703 });
704
705 let patch = json!([
706 {"op": "remove", "path": "/value"}
707 ]);
708
709 let result = apply_json_patch(&original, &patch).unwrap();
710 assert!(result.get("value").is_none());
711 }
712
713 #[test]
714 fn test_json_patch_replace() {

Callers

nothing calls this directly

Calls 1

apply_json_patchFunction · 0.70

Tested by

no test coverage detected