Support null vs noop comparison.

This commit is contained in:
Tom Alexander 2023-12-30 20:47:17 -05:00
parent aa5629354e
commit d258cdb839
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

View File

@ -156,6 +156,9 @@ fn compare_optional_json_value<'b, 's>(
(None, None) | (None, Some(serde_json::Value::Null)) | (Some(Token::Atom("nil")), None) => {
Ok(WasmDiffResult::default())
}
(None, Some(serde_json::Value::Object(w))) if w.contains_key("noop") => {
Ok(WasmDiffResult::default())
}
(Some(e), Some(w)) => compare_json_value(source, e, w),
_ => Ok(WasmDiffResult {
status: vec![WasmDiffStatus::Bad(