From 6130a0d0f318e5ae922f762ac9300f1c7ac654d2 Mon Sep 17 00:00:00 2001 From: Simon Cropp Date: Sat, 11 May 2024 18:22:13 +1000 Subject: [PATCH 1/2] Update AdditionalInformationTests.cs --- .../Namer/AdditionalInformationTests.cs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs b/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs index f4d65d82..02d0197f 100644 --- a/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs +++ b/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs @@ -74,13 +74,11 @@ public void WithMultiplePartScenarioData(string a, string b) public void TestMultipleNames() { using (ApprovalResults.ForScenario("scenario")) + using (ApprovalResults.ForScenario("machineName")) { - using (ApprovalResults.ForScenario("machineName")) - { - var name = Approvals.GetDefaultNamer().Name; - Assert.AreEqual(name, - "AdditionalInformationTests.TestMultipleNames.ForScenario.scenario.ForScenario.machineName"); - } + var name = Approvals.GetDefaultNamer().Name; + Assert.AreEqual(name, + "AdditionalInformationTests.TestMultipleNames.ForScenario.scenario.ForScenario.machineName"); } } From 94d7c2815ecbee80ac4874c74aeef740f1185cd7 Mon Sep 17 00:00:00 2001 From: Simon Cropp Date: Sat, 11 May 2024 18:22:45 +1000 Subject: [PATCH 2/2] Revert "Update AdditionalInformationTests.cs" This reverts commit 6130a0d0f318e5ae922f762ac9300f1c7ac654d2. --- .../Namer/AdditionalInformationTests.cs | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs b/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs index 02d0197f..f4d65d82 100644 --- a/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs +++ b/src/ApprovalTests.Tests/Namer/AdditionalInformationTests.cs @@ -74,11 +74,13 @@ public void WithMultiplePartScenarioData(string a, string b) public void TestMultipleNames() { using (ApprovalResults.ForScenario("scenario")) - using (ApprovalResults.ForScenario("machineName")) { - var name = Approvals.GetDefaultNamer().Name; - Assert.AreEqual(name, - "AdditionalInformationTests.TestMultipleNames.ForScenario.scenario.ForScenario.machineName"); + using (ApprovalResults.ForScenario("machineName")) + { + var name = Approvals.GetDefaultNamer().Name; + Assert.AreEqual(name, + "AdditionalInformationTests.TestMultipleNames.ForScenario.scenario.ForScenario.machineName"); + } } }