All Questions
4 questions
1
vote
2
answers
195
views
PHP unit test to confirm that a validator is being called correctly
I have a Responder class whose prepare method takes an entity, checks it with a validator, and returns a response or errorResponse based on the results of validator....
3
votes
2
answers
166
views
PHPUnit test for a PaymentMethodRuleManager
The following code snippet is about adding rules that filters Payment Methods listing to customer, for email we provide 4 different types of payment methods, but we do show them depending on some ...
4
votes
1
answer
140
views
Testing a Pivotal API request client using lots of mocking
I have a class that is all about doing HTTP requests, and logging (in file system & database). It's only using 3 dependencies to do these things, so I'm fine with the code so far.
Here it is for ...
5
votes
1
answer
471
views
Mock user table class
I've just created my first tests using mock classes. So far my tests are running much faster and now I guess I'm solely focusing on a single class (in this case I'm testing UserTable and mocking the ...