Ellisande / mockolate

Simple mocking framework for JS
MIT License
1 stars 3 forks source link

In Order Stubbing #4

Open Ellisande opened 8 years ago

Ellisande commented 8 years ago

What kind of issue is this? (bug, feature, etc)

Feature

What is the proposed change?

Implement a way for the same mockFunction with the same parameters to return different results on successive functions.

Why will this be beneficial?

Could be useful for stubbing out methods that mutate an underlying variable. For instance, a method that increases a counter each time its invoked and returns the result.

Misc. info

I think this is probably a 10% or less case. Low priority.