diff --git a/src/Orchard.Specs/Bindings/WebAppHosting.cs b/src/Orchard.Specs/Bindings/WebAppHosting.cs index 3605a8112..08670ec99 100644 --- a/src/Orchard.Specs/Bindings/WebAppHosting.cs +++ b/src/Orchard.Specs/Bindings/WebAppHosting.cs @@ -191,7 +191,7 @@ namespace Orchard.Specs.Bindings { _doc.Load(new StringReader(Details.ResponseText)); } - [When(@"I follow ""(.*)""")] + [When(@"I follow ""([^""]*)""")] public void WhenIFollow(string linkText) { var link = _doc.DocumentNode .SelectNodes("//a") @@ -204,7 +204,7 @@ namespace Orchard.Specs.Bindings { WhenIGoTo(urlPath); } - [When(@"I follow ""(.*)"" where href has (.+)$")] + [When(@"I follow ""([^""]+)"" where href has ""([^""]+)""")] public void WhenIFollow(string linkText, string hrefFilter) { var link = _doc.DocumentNode .SelectNodes("//a[@href]").Where(elt => diff --git a/src/Orchard.Specs/Lists.feature b/src/Orchard.Specs/Lists.feature index eeeba140c..cac77f999 100644 --- a/src/Orchard.Specs/Lists.feature +++ b/src/Orchard.Specs/Lists.feature @@ -25,9 +25,9 @@ Scenario: I can add content items to a list Then I should see "MyList" When I follow "Contained Items" Then I should see "The 'MyList' List has no content items." - When I follow "Create New Content" where href has ReturnUrl + When I follow "Create New Content" where href has "ReturnUrl" Then I should see "MyType" - When I follow "MyType" where href has ReturnUrl + When I follow "MyType" where href has "ReturnUrl" And I fill in | name | value | | Routable.Title | MyContentItem | diff --git a/src/Orchard.Specs/Lists.feature.cs b/src/Orchard.Specs/Lists.feature.cs index 15b8151ea..830812173 100644 --- a/src/Orchard.Specs/Lists.feature.cs +++ b/src/Orchard.Specs/Lists.feature.cs @@ -115,11 +115,11 @@ this.ScenarioSetup(scenarioInfo); #line 27 testRunner.Then("I should see \"The \'MyList\' List has no content items.\""); #line 28 - testRunner.When("I follow \"Create New Content\" where href has ReturnUrl"); + testRunner.When("I follow \"Create New Content\" where href has \"ReturnUrl\""); #line 29 testRunner.Then("I should see \"MyType\""); #line 30 - testRunner.When("I follow \"MyType\" where href has ReturnUrl"); + testRunner.When("I follow \"MyType\" where href has \"ReturnUrl\""); #line hidden TechTalk.SpecFlow.Table table3 = new TechTalk.SpecFlow.Table(new string[] { "name",