Open vpratfr opened 7 years ago
That's an interesting option too; I haven't tried it that way! I think it would work well though, I'll have to give it a shot. Thanks!
Usually I use it to cover edge cases in test methods to pass in different sets of parameters. But when testing contracts, it makes it very easy to add implementations to the contract test.
One drawback though is that by using it there, you cannot have any additional provider if you want to make the test input vary.
You mention 2 options: base class or traits.
According to me, another very valid one would be to create a common test class which would run each methods with a parameter. Then use a provider to switch payment gateways.
What are your thoughts about this option?