tag:blogger.com,1999:blog-33777038.post1719812420095379827..comments2024-03-28T06:50:57.354+00:00Comments on programmer.grrl: Misadventures In BDD With NBehaveprogrammergrrlhttp://www.blogger.com/profile/08045944515241515020noreply@blogger.comBlogger5125tag:blogger.com,1999:blog-33777038.post-31820009956699462932017-11-14T12:09:22.111+00:002017-11-14T12:09:22.111+00:00tenks you coments postingtenks you coments postingobat penggugur kandunganhttp://obat-aborsi99.com/noreply@blogger.comtag:blogger.com,1999:blog-33777038.post-7754951043491986882010-04-08T00:00:30.356+01:002010-04-08T00:00:30.356+01:00There are some new ways currently available on the...There are some new ways currently available on the NBehave trunk to write tests (will be included in v0.5). I've posted about them at http://www.sharpfellows.com/post/NBehave-Different-ways-to-drive-BDD-tests-specs.aspx.John Raynerhttp://www.sharpfellows.com/noreply@blogger.comtag:blogger.com,1999:blog-33777038.post-85106251910709557752009-08-11T22:05:29.891+01:002009-08-11T22:05:29.891+01:00@Morgan
That's awesome. I had no idea NBehave ...@Morgan<br />That's awesome. I had no idea NBehave could do that.<br /><br />@Arnt<br />And I didn't know you could do that either. Good stuff.<br /><br />Yep, I have a bit to learn about NBehave.programmergrrlhttps://www.blogger.com/profile/08045944515241515020noreply@blogger.comtag:blogger.com,1999:blog-33777038.post-1286346218282325022009-08-10T12:22:43.188+01:002009-08-10T12:22:43.188+01:00If you made your test take parameters from the tex...If you made your test take parameters from the text. You would correct the numbers in your text. Your functions can take parameters. I'v writen my storyes like this<br /><br />story.AsA("Bowler")<br />.IWant("The score of my game to be calculated")<br />.SoThat("I can know my total score");<br /><br />story.WithScenario("Gutter game")<br />.Given("a game of bowling", () => g = new Game())<br />.When("All my $rolls rolls are $pins", 20, 0, RollMany)<br />.Then("My score should be $score", 0, (expectedScore) => <br /> g.Score().ShouldEqual(expectedScore));<br /><br /><br />Now for the second story i can write.<br />story.WithScenario("All once")<br />.Given("a game of bowling")<br />.When("All my 20 rolls are 1")<br />.Then("My score should be 20");<br /><br />Since i have declared the sentence template it will run the RollManny function with parameters<br />20 rols and 1 pin in each roll.Arnthttps://www.blogger.com/profile/13702234685939477289noreply@blogger.comtag:blogger.com,1999:blog-33777038.post-67206023905733901332009-08-09T21:26:15.572+01:002009-08-09T21:26:15.572+01:00Why dont you just execute the text instead? See ht...Why dont you just execute the text instead? See http://nbehave.codeplex.com/Wiki/View.aspx?title=With%20textfiles%20and%20ActionSteps&referringTitle=HomeMorganhttps://www.blogger.com/profile/10530834219569757336noreply@blogger.com