diff --git a/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_Patching.cpp b/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_Patching.cpp index 046bb88d76..15c3c8f71b 100644 --- a/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_Patching.cpp +++ b/Code/Framework/AzCore/Tests/Serialization/Json/TestCases_Patching.cpp @@ -71,10 +71,7 @@ namespace JsonSerializationTests const AZ::JsonApplyPatchSettings& settings = AZ::JsonApplyPatchSettings{}) { CheckApplyPatchOutcome(target, patch, outcome, processing, settings); - rapidjson::Document expectedPatchedDocument; - expectedPatchedDocument.Parse(expectedPatchedResult); - ASSERT_FALSE(expectedPatchedDocument.HasParseError()); - EXPECT_EQ(AZ::JsonSerialization::Compare(expectedPatchedDocument, *m_jsonDocument), AZ::JsonSerializerCompareResult::Equal); + Expect_DocStrEq(expectedPatchedResult); } void CheckCreatePatch_Core(const char* source, AZStd::string_view patch, const char* target, diff --git a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabUndo.cpp b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabUndo.cpp index 728b95f74b..7d9fb64c96 100644 --- a/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabUndo.cpp +++ b/Code/Framework/AzToolsFramework/AzToolsFramework/Prefab/PrefabUndo.cpp @@ -265,8 +265,8 @@ namespace AzToolsFramework AZ_Error( "Prefab", - result.GetOutcome() != AZ::JsonSerializationResult::Outcomes::PartialSkip && - result.GetOutcome() != AZ::JsonSerializationResult::Outcomes::Success, + result.GetOutcome() == AZ::JsonSerializationResult::Outcomes::PartialSkip || + result.GetOutcome() == AZ::JsonSerializationResult::Outcomes::Success, "Some of the patches are not successfully applied."); //remove the link id placed into the instance