diff --git a/CHANGELOG.md b/CHANGELOG.md index cd572fbd..8d64a7be 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -13,6 +13,10 @@ This project adheres to [Semantic Versioning](http://semver.org/). ### Removed +- Removed `times_any` and `times_range` methods from Expectations. They've + been deprecated since 0.3.0. + ([#196](https://github.com/asomers/mockall/pull/196)) + ## [0.8.0] - 29 August 2020 ### Added - Added support for mocking structs and traits with associated constants. diff --git a/mockall_derive/src/mock_function.rs b/mockall_derive/src/mock_function.rs index 2c96c971..ab2451e4 100644 --- a/mockall_derive/src/mock_function.rs +++ b/mockall_derive/src/mock_function.rs @@ -975,26 +975,6 @@ impl<'a> ToTokens for CommonExpectationMethods<'a> { self } - /// Allow this expectation to be called any number of times - /// - /// This behavior is the default, but the method is provided in case the - /// default behavior changes. - #[deprecated(since = "0.3.0", note = "Use times instead")] - #v fn times_any(&mut self) -> &mut Self { - self.common.times(..); - self - } - - /// Allow this expectation to be called any number of times within a - /// given range - #[deprecated(since = "0.3.0", note = "Use times instead")] - #v fn times_range(&mut self, __mockall_range: Range) - -> &mut Self - { - self.common.times(__mockall_range); - self - } - /// Set matching crieteria for this Expectation. /// /// The matching predicate can be anything implemening the @@ -1210,22 +1190,6 @@ impl<'a> ToTokens for ExpectationGuardCommonMethods<'a> { #expectations.0[self.i].times(__mockall_r) } - /// Just like - /// [`Expectation::times_any`](struct.Expectation.html#method.times_any) - #[deprecated(since = "0.3.0", note = "Use times instead")] - #v fn times_any(&mut self) -> &mut Expectation #tg { - #expectations.0[self.i].times(..) - } - - /// Just like - /// [`Expectation::times_range`](struct.Expectation.html#method.times_range) - #[deprecated(since = "0.3.0", note = "Use times instead")] - #v fn times_range(&mut self, __mockall_range: Range) - -> &mut Expectation #tg - { - #expectations.0[self.i].times(__mockall_range) - } - /// Just like /// [`Expectation::with`](struct.Expectation.html#method.with) #v fn with<#with_generics> (&mut self, #with_args)