Is their any way to have multiple parameters in one test instead of copying and pasting the function again?
Example in NUnit for C#:
[TestCase("0", 1)]
[TestCase("1", 1)]
[TestCase("2", 1)]
public void UnitTestName(string input, int expected)
{
//Arrange
//Act
//Assert
}
What I want in Js:
describe("<Foo />", () => {
[TestCase("false")]
[TestCase("true")]
it("option: enableRemoveControls renders remove controls", (enableRemoveControls) => {
mockFoo.enableRemoveControls = enableRemoveControls;
//Assert that the option has rendered or not rendered the html
});
});