public IActionResult Excercise6(string value) { var stringTransformer = new StringTransformer(); try { ViewBag.Result = stringTransformer.Reverse(value); } catch (Exception e) { ViewBag.Error = e.Message; } return(View()); }
public void TestStringTransformerReverse(string value, string result) { var stringTransformer = new StringTransformer(); Assert.Equal(result, stringTransformer.Reverse(value)); }