From 31c3f5ae0c627bd0b4d13377a74ef0e6051e43b4 Mon Sep 17 00:00:00 2001 From: Sven Geusens Date: Wed, 23 Apr 2025 07:09:00 +0200 Subject: [PATCH] Remove fake null checks as they are no longer needed after merge into v16 (#19109) --- .../BlockListElementLevelVariationTests.Editing.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/Umbraco.Tests.Integration/Umbraco.Infrastructure/PropertyEditors/BlockListElementLevelVariationTests.Editing.cs b/tests/Umbraco.Tests.Integration/Umbraco.Infrastructure/PropertyEditors/BlockListElementLevelVariationTests.Editing.cs index d7e8ffc5cb..c6f2dff383 100644 --- a/tests/Umbraco.Tests.Integration/Umbraco.Infrastructure/PropertyEditors/BlockListElementLevelVariationTests.Editing.cs +++ b/tests/Umbraco.Tests.Integration/Umbraco.Infrastructure/PropertyEditors/BlockListElementLevelVariationTests.Editing.cs @@ -555,8 +555,7 @@ internal partial class BlockListElementLevelVariationTests content = ContentService.GetById(content.Key); var savedBlocksValue = content?.Properties["blocks"]?.GetValue()?.ToString(); - Assert.NotNull(savedBlocksValue); - blockListValue = JsonSerializer.Deserialize(savedBlocksValue); + blockListValue = savedBlocksValue is null ? null : JsonSerializer.Deserialize(savedBlocksValue); // limited user access means invariant data is inaccessible since AllowEditInvariantFromNonDefault is disabled if (updateWithLimitedUserAccess) @@ -973,7 +972,7 @@ internal partial class BlockListElementLevelVariationTests } else { - Assert.AreEqual("null", savedBlocksValue); + Assert.IsNull(savedBlocksValue); } }