eproxus / meck

A mocking library for Erlang
http://eproxus.github.io/meck
Apache License 2.0
811 stars 231 forks source link

Deprecate history and provide history digging functions instead #85

Closed horkhe closed 7 years ago

horkhe commented 11 years ago

Test writers do not need entire history. They need a convenient way to find out some specific facts about the history like called and num_calls functions. By providing them entire history we kind of forcing them to write custom information retrieval and verification functions.

I believe a better way would be to provide a comprehancive set of history digging functions, such as:

That probably covers everything a testing human being might need.

eproxus commented 11 years ago

+1

Although history/1 should probably be left since people might want to build their own hacks on top of it (but with the documented caveat that the return format might change in future versions).

horkhe commented 11 years ago

We won't delete it, we will just deprecate it.

eproxus commented 11 years ago

I would like it to stay as not deprecated, perhaps hidden or just "marked" as non-reliable (between versions).

eproxus commented 7 years ago

Closing and documenting in the wiki instead: https://github.com/eproxus/meck/wiki#feature-ideas

Please comment here if you have information or requests to add, and/or want to discuss a PR or possible implementation proposal.