Releases: lipanski/mockito
Releases · lipanski/mockito
0.9.1
0.9.0
0.8.2
0.8.1
0.8.0
- Rewrote part of the internal implementation of Mockito, replacing the client/server approach with a singleton state controlled through a mutex. Long story short, this removed the need for curl and serde as dependencies and significantly improved the response time.
0.7.2
- The
Mock#assert
error message now prints out the last unmatched request as well:Expected 1 request(s) to: POST /users bob ...but received 0 The last unmatched request was: POST /users content-length: 5 alice
- Turned request headers into
Vec
, instead ofHashMap
to solve the sorting problem once and for all. - Namespaced the internal API with
/mockito
.
0.7.1
0.7.0
- Introduced the
Mock#assert
method to assert that a mock was called. You can useMock#expect
to specify the number of requests you're expecting. Check the docs for more details. - [Breaking] Mocks will be automatically cleaned up whenever their lifetime ends. This is the more Rusty approach to having to call
Mock#remove
orreset
explicitly. You'll want to assign your mock to a variable in order to establish its lifetime. Check the docs for examples. - [Breaking] The
Mock#remove
method has been removed (or better said, it's private now). You can usestd::mem::drop
if you really need to remove a mock before its lifetime ends. - [Breaking] The
Mock#create_for
method has been removed. Normal Rust closures{ ... }
and the lifetimes should replace this just fine. - [Breaking] Builder-pattern methods of the
Mock
struct are now returningMock
instead of&mut Mock
. - Established clearer boundries between the mock server and the mock client.