I am new to c# unit testing. I am curious if it is possible to parameterize the SetUp method that is decorated by [TestInitialize]
[TestInitialize]
public void SetUp(string path)
{
fileStream = new FileStream(path, FileMode.Open);
binaryReader = new BinaryReader(fileStream);
}
For example, before each test, I want to be able to pass a unique path to SetUp. Can this be done? I have consulted this post: How to run a test method with multiple parameters in MSTest? but it does not quite address the problem I am trying to solve, and if it is even possible. Thanks to all of those who respond in advance!