public HomeModule() { Get["/"] = _ => View["index.cshtml"]; Post["/result"] = _ => { RepeatCounter counter = new RepeatCounter(); return(View["result.cshtml", counter.CounterRepeats(Request.Form["userWord"], Request.Form["userStrings"])]); }; }
public void RepeatCounterCheck_ForUserInput_0() { RepeatCounter repeatCounterTest = new RepeatCounter(); Assert.Equal(0, repeatCounterTest.CounterRepeats("", "")); }
public void RepeatCounterCheck_ForUserInputHELLO_HerloHEllohelloHELLO_2() { RepeatCounter repeatCounterTest = new RepeatCounter(); Assert.Equal(3, repeatCounterTest.CounterRepeats("HELLO", "Herlo HEllo hello HELLO")); }
public void RepeatCounterCheck_ForUserInputHello_HelloGoodbyeHello_2() { RepeatCounter repeatCounterTest = new RepeatCounter(); Assert.Equal(2, repeatCounterTest.CounterRepeats("Hello", "Hello Goodbye Hello")); }