Change Log

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

Unreleased

0.9.2 - 2021-03-06

Fixed

  • Fix a Dialyzer warning on OTP 24 #223

0.9.1 - 2021-02-17

Fixed

  • Module references in type specs were not included when renaming modules #206
  • The passthrough clause was not always the last clause in an expect with multiple clauses #216

0.9.0 - 2020-06-25

Added

  • Support Erlang 23.0 8c16751
  • Add a new function mocked/0 that returns which modules are currently mocked #210

Changed

  • Validate the options being passed to meck:new #204

Fixed

  • Do not attempt to generate dependencies when mocking 9b3ce75
  • Add compiler application to dependencies #209
  • meck:ret_spec() opaqueness violates documented usage patterns #212

0.8.13 - 2019-01-08

Removed

  • Remove compatibility for Erlang R15 and R16 #198

Fixed

  • Crash when mocking Elixir 1.8-rc.0 compiled module #201
  • Exclude from_core option from compile_info when compiling #202 (josevalim)
  • Isolate backup *.coverdata from other beam instances #200 (dcsommer)

0.8.12 - 2018-08-08

Fixed

  • History item is not kept while module compiler is running #194

0.8.11 - 2018-07-12

Fixed

0.8.10 - 2018-06-26

Added

0.8.9 - 2017-11-27

Changed

  • Migrate to Rebar 3 and rebar3_hex #155

Fixed

  • Support running meck with modules built with ‘+deterministic’ compileā€¦ #185 (nablaa)
  • How do I run coverage results after using meck? #181
  • Fix for Rebar 2.x.y on secondary arches #183 (lemenkov)

0.8.8 - 2017-08-29

Changed

Fixed

  • {:error, {:no\_abstract\_code, ...}} with Elixir 1.5.0-rc.0 and Erlang 20.0 #179

0.8.7 - 2017-06-29

Fixed

  • Remove dialyzer attributes when creating mock (Erlang 20.0) #178

0.8.6 - 2017-06-28

Fixed

  • Remove dialyzer attributes when creating mock 3b772d0

0.8.5 - 2017-06-28

Added

  • Support Erlang 20 #175
  • Support Erlang 19 #168 (WramblinWreck)
  • Add meck:get_state/0, meck:reset_state/0 #125
  • Add meck:result/4-5 that returns the result value of a particular function #163 (amutake)

Deprecated

  • Deprecate history and provide history digging functions instead #85
  • fix #88 #162 (yutopp)

Fixed

  • Mocked module will return empty function clause error #167
  • Deleting an expectation in passthrough mode does not restore original function #88
  • Passthrough crashes without +debug_info #14
  • fix behavio(u)r attributes validation on Erlang R20 #176 (RoadRunnr)
  • Fix errors in capture/5, capture/6 documentation #172 (marco-m)
  • Fix eunit compile failure on Erlang 17+ (hamcrest) #161 (marco-m)

0.8.4 - 2015-12-29

Added

Changed

  • Update ‘problematic modules list’ #156 (lilrooness)
  • Document the caveat with mocking module-local calls. #145 (bpuzon)

Fixed

0.8.3 - 2015-06-09

Added

Changed

Fixed

  • Please document that modules can be not meck'able #135
  • crypto module #59
  • Fix variable exported from case #128 (hazardfn)

0.8.2 - 2014-05-05

Added

  • Suport Erlang 17.0 and Erlang R16B03-1 #118 (myers)

    Add Erlang 17.0 to the test matrix #122 (myers)

  • Implicit new #80

  • Should return compilation errors #33

  • Better documentation #79

Changed

  • Put non-strict option in the README.md #117
  • Split tests into several test suites #83

Fixed

  • With a bogus test instantiator, meck fails with {error, enoent} in meck_cover:read_cover_file/1 #114
  • Unable to mock lists module #87
  • Do not consider a 3-tuple return value as an exception #113 (lucafavatella)

0.8.1 - 2013-08-29

Fixed

0.8 - 2013-08-17

Added

  • Support R16B #100 (rufrozen)

  • Capture argument #86

    Feature/capture #97 (horkhe)

  • Wait for a number of function calls #81

    Wait for a number of calls feature (#81) #99 (horkhe)

  • Mocking of parameterized modules #4

  • Allow calling original function from within expect fun #2

  • Make remote_setup more robust #109 (i11)

  • Implement ‘implicit new’ feature #80 #104 (horkhe)

  • Make undefined\_module error contain module name #96 (horkhe)

  • Introduce support for matchers: #89 (horkhe)

  • Feature/file bif passthrough #84 (horkhe)

  • Two new options for meck #77 (norton)

  • Feature/honest mocks #75 (horkhe)

  • Feature/new exception syntax #74 (horkhe)

  • Extended expect syntax and more #73 (horkhe)

  • Introduce ‘stub_all’ option #78 (horkhe)

  • Support for location included in stack traces in Erlang R15 #52 (bjnortier)

Changed

  • Make passthrough/1 and func/1 into a ret\_specand func #91 (horkhe
  • Refactor meck into smaller functional modules #82 (horkhe)

Removed

  • R16A preview - parameterized modules are no longer supported #94
  • Remove unsupported option from the app.src file #101 (amiramix)
  • Remove parametrized module test #95 (norton)

Fixed

0.7.2 - 2012-05-06

Added

  • Remove Erlang R15B support #54 (michaelklishin)
  • Mocking of sticky modules #7
  • Rz passthrough cover #56 (rzezeski)
  • Mock parametrized modules #55 (shino)
  • Clean test directory #50 (norton)
  • New features - pid in history and count_calls and wildcard_count_calls functions #40 (daha)
  • Include meck:new/2 arguments in errors #39 (legoscia)
  • .travis.yml config without rebar #38 (wardbekker)
  • Filter out parse_transforms from compilation options #32 (djnym)

Changed

  • remove repetition; typo #57 (Erkan-Yilmaz)
  • Improved tests: Added an ok in the end of the tests that use a helper function with asserts #43 (daha)
  • Making all the test funs in the foreach in meck_test_/0 fully qualified funs #44 (daha)

Removed

Fixed

  • dialyzer warnings with meck (73c0b3e) #58
  • Inconsistency in documentation #49
  • meck:unload/0 sometimes crashes #48
  • Add test/cover_test_module.beam to rebar.config's clean files #47
  • Fix typo in no_passthrough_cover atom #62 (garret-smith)
  • Verify history/2 returns events in the correct order & fix to flaky history_by_pid_/1 test #42 (daha)

0.7.1 - 2011-07-18

Fixed

  • Can I call original function with different arguments? #30

0.7 - 2011-07-13

Added

  • Enable mocking of sticky modules (not used by code_server) #29 (xenolinguist)

0.6.3 - 2011-06-30

Changed

  • Interface inconsistency #8

0.6.2 - 2011-06-09

  • Fix re adding shortcut expects 9b8934a
  • Fix returning of opaque terms in shortcut expectations b1904a2

0.6.1 - 2011-06-08

Added

Fixed

  • Makefile requires local rebar and documentation says rebar on path #28

0.6 - 2011-05-25

Added

  • Add loop/4 expect function 8d86012
  • Add sequence/4 expect function 35de01e

0.5.1 - 2011-05-23

Changed

  • Replace fail_on_warning with warnings_as_errors ddd9e3b

0.5 - 2011-04-12

Added

  • Add meck:received/3 API for easier history checking #23 (mbbx6spp)

Fixed

  • dialyzer unmatched return errors #24