From 2af2326638d75f9136c09ce7f95c81134b1bf607 Mon Sep 17 00:00:00 2001 From: Kristian Hellang Date: Thu, 15 Sep 2016 09:40:08 +0200 Subject: [PATCH] Remove assert on exception message. Fixes #2565 --- test/Nancy.Tests/Unit/HttpLinkFixture.cs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/test/Nancy.Tests/Unit/HttpLinkFixture.cs b/test/Nancy.Tests/Unit/HttpLinkFixture.cs index 6ea76ee8c9..42eae75662 100644 --- a/test/Nancy.Tests/Unit/HttpLinkFixture.cs +++ b/test/Nancy.Tests/Unit/HttpLinkFixture.cs @@ -12,11 +12,8 @@ public void Add_duplicate_parameter_in_different_casing_throws_argument_exceptio var link = new HttpLink("http://nancyfx.org/", "home"); link.Parameters.Add("up", "up"); - // When - var exception = Assert.Throws(() => link.Parameters.Add("UP", "UP")); - - // Then - exception.Message.ShouldEqual("An item with the same key has already been added."); + // When, Then + Assert.Throws(() => link.Parameters.Add("UP", "UP")); } [Fact]