Ecosyste.ms: OpenCollective

An open API service for software projects hosted on Open Collective.

github.com/freerange/mocha

A mocking and stubbing library for Ruby
https://github.com/freerange/mocha

Add Ruby v3.3 to CI build matrix

ce31b544ca765b930db1dcbb02570863bc7c24eb authored about 1 year ago by James Mead <[email protected]>
Improve sequence failure message

I think there's more we could do in this area, but this implements
@dchelimsky's suggestion whic...

0800c6ffadb3c08583b628a827fc0306552c28f4 authored about 1 year ago by James Mead <[email protected]>
Add block syntax for sequences

All expectations defined within the block are constrained by the
sequence.

For example, the fol...

93fdffd48a51df1215542ace562bcc0b89757d5d authored about 1 year ago by James Mead <[email protected]>
Add missing YARD tag for API#states name param

f798df83b34fb9d99a9da5c4988a16c5f63f9b88 authored about 1 year ago by James Mead <[email protected]>
Add missing YARD tag for API#sequence name param

343c597924c8afc1d2c9464698544bda8d6613a2 authored about 1 year ago by James Mead <[email protected]>
Use Ruby v1.9 Hash syntax in docs

We updated the code to use Ruby v1.9 Hash syntax in #598. This brings
the docs into line with th...

6de207260fd7a86347a42ae317a47633b497a903 authored about 1 year ago by James Mead <[email protected]>
Merge pull request #626 from freerange/tidy-up-minitest-modules

Tidy up Minitest vs MiniTest references

e7134d55ffb1f95f6e2344aa6b5be676463d3ed8 authored about 1 year ago by James Mead <[email protected]>
Use minitest vs mini_test everywhere

As noted by @zenspider in this comment [1], the rename is over 10 years
old, so it seems about t...

a13e1e4c168ca7eb2d5108ab89ce06ec6cd3f4c4 authored about 1 year ago by James Mead <[email protected]>
Use Minitest vs MiniTest everywhere

All of these are either references to constants internal to Mocha or
documentation referencing t...

7375af61a271d424662f0af426134d945a598cbc authored about 1 year ago by James Mead <[email protected]>
Do not require "minitest/unit"

As per this comment [1]. Thanks, @Maimer!

As of Minitest v5.19.0 [2], there's no need to requir...

70a36b901c404b192f0ac24e722957186aeb3016 authored about 1 year ago by James Mead <[email protected]>
Reduce duplication in identifying Minitest version

We've had `Mocha::Detection::MiniTest.version` for some time and it does
a more thorough job tha...

6f2be6f31572f77dfc057256a513930e64f21ac1 authored about 1 year ago by James Mead <[email protected]>
Support multiple methods in responds_with matcher

This provides a terser syntax for matching an object which responds in a
certain way, e.g.

...

f086b7e40f9fb9240671641e6e568c87c028ef22 authored about 1 year ago by James Mead <[email protected]>
Reinstate missing CNAME for GitHub Pages site

da67bb0dd4d1ba83ef0f4cd3c0efa5a9fb60ee05 authored about 1 year ago by James Mead <[email protected]>
[skip ci] Update docs to fix those for Mock#method_missing

cee0bad637b43d7c6548b1d70f94f9db9b12f034 authored about 1 year ago by James Mead <[email protected]>
Avoid rubocop directive ending up in YARD docs

It turns out that YARD displays a special section "Dynamic Method
Handling" for classes that imp...

2a9ee81a5abc396c83c5365a674cd2452a17cc0b authored about 1 year ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.1.0

25ed0e59107ea584154f94e77b128af556b7f9a2 authored over 1 year ago by James Mead <[email protected]>
Bump version to 2.1.0 & prepare for release

f65a74727497d74787aad8cb3ea0212e76a48acc authored over 1 year ago by James Mead <[email protected]>
Fix Mocha/Minitest compatibility

It turns out we were relying on the very old [1] MiniTest module name
rather than the newer Mini...

32ef48f410189bb26abe574218306b612fc4de89 authored over 1 year ago by James Mead <[email protected]>
Update URLs for links to Ruby & MIT licenses

d6470af47263413bc697a7d13c4ef2dd11bf04b1 authored over 1 year ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.4.

345f042be22c89d1a72d4f971bc1362f02a66658 authored over 1 year ago by James Mead <[email protected]>
Bump version to 2.0.4 & prepare for release

d07c1f60a1e2dd7dba0c57f2959e61eb712caa5b authored over 1 year ago by James Mead <[email protected]>
Update README.md

e8c21e1bc01ba499b94d3ed0d96ea64dd011dcbb authored over 1 year ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.3.

f409e3a24a38f0413d0f23231741bdc12f336396 authored over 1 year ago by James Mead <[email protected]>
Bump version to 2.0.3 & prepare for release

ddef48fe156a610fc761f397d1d90da797f1acde authored over 1 year ago by James Mead <[email protected]>
Update COPYING.md

f3152376c469aac806f35dcaeac19389a4ce0d50 authored over 1 year ago by James Mead <[email protected]>
Update MIT-LICENSE.md

48162b4eca75063abe52513cf921f059de0da964 authored over 1 year ago by James Mead <[email protected]>
Remove Google Analytics tracking code

I never look at the data from this and in any case I don't ask
permission to track people on the...

2279c49dd01895ced5cc7a74f63a1ba5e5ba73bf authored over 1 year ago by James Mead <[email protected]>
Revert "Pin yard version to v0.9.28 to avoid ArgumentError"

This reverts commit 12f1eef7dbe7cd65104327b6a958cf3b8f50989a.

The problem I reported in lsegal/...

7c6c10c509599956cdd07763d12228b655ea3f40 authored over 1 year ago by James Mead <[email protected]>
Remove invalid CircleCI token from badge URL

I'm not sure why/when this token became invalid, but I suspect it was a
while back when there we...

7078e76a569b09b8ef8d1109a48b05b5f7a44a0e authored over 1 year ago by James Mead <[email protected]>
Revert "Pin JRuby to v9.3.9.0 in CircleCI builds"

This reverts commit b8e6d064b8b9bfeb37d6534bbb4e37856dfec5b7.

The problem identified in #591 wa...

4f5bb2f090df10164ba9502ebd615f1d241cc5b5 authored over 1 year ago by James Mead <[email protected]>
Pin yard version to v0.9.28 to avoid ArgumentError

It seems as if the recent v0.9.29 release of yard broke my custom
template code. I plan to repor...

12f1eef7dbe7cd65104327b6a958cf3b8f50989a authored over 1 year ago by James Mead <[email protected]>
Use Ruby v2.6 vs v2.2 to run lint CI job

It seems as if recent versions of minitest now require a more recent
version of Ruby. Without th...

af40b7dbbc2999e4be68188eccccb3fdd7f06206 authored over 1 year ago by James Mead <[email protected]>
Add Ruby v3.2 to CircleCI build

Ruby v3.2.0 was recently released [1].

[1]: https://www.ruby-lang.org/en/news/2022/12/25/ruby-3...

f7e17636ac66c031f1914f7ee4b32b6a3e7d2353 authored about 2 years ago by James Mead <[email protected]>
Remove Ruby version check from RespondsLikeTest

Mocha >= v2 only supports Ruby >= v2 and so this check is redundant in
the main branch.

21583129c553aa3035346e5a0ad4dcb22dee1d74 authored about 2 years ago by James Mead <[email protected]>
Rubocop: enable Style/FormatStringToken cop

Since support for Ruby 1.8 has been dropped.

089a688e0bd5a6f171c1fc914d8c858c72c32221 authored about 2 years ago by Herwin Weststrate <[email protected]>
Pin JRuby to v9.3.9.0 in CircleCI builds

Currently 4 tests are failing in JRuby v9.4.0.0, e.g. this build [1].

This is due to a JRuby is...

b8e6d064b8b9bfeb37d6534bbb4e37856dfec5b7 authored about 2 years ago by James Mead <[email protected]>
Simplify storage of MOCHA_OPTIONS

This has only ever supported `debug`, `verbose` & `skip_integration`
options. However, it curren...

b70507a13b99c1a026216fc44a0a6e8c413e5f43 authored about 2 years ago by Herwin Weststrate <[email protected]>
Use Ruby 1.9 hash syntax

Fixes #537

8bc0ad2f343f70c06c6c8278e4307a26bbc9e4ee authored about 2 years ago by Herwin Weststrate <[email protected]>
Fix BacktraceFilter to handle special characters

We do regular testing of ruby-head, so our gem paths include a `+`
which has a special meaning i...

e242033ff9e1e054ad3efeaa8ca79058aa442f5a authored about 2 years ago by Jean Boussier <[email protected]>
Fix regexp_matches tests in Ruby v3.2

Object#~= has been removed from Ruby v3.2 [1].

Closes #590.

[1]: https://bugs.ruby-lang.org/is...

26b106a540ad57cd73401461451aa2711c541e9d authored about 2 years ago by James Mead <[email protected]>
DRY up regexp_matches test

ae9fed4a9f2ef6267302494ae0edf515d4a8a921 authored about 2 years ago by James Mead <[email protected]>
Add Ruby v3.1 to the CircleCI build

In preparation for the release of Ruby v3.2.

3e460489f7a677fc2cc2c78a887dc7755e551d75 authored about 2 years ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.2.

f4a858d9ec3d44762abf22ca84f0af277a2a0651 authored about 2 years ago by James Mead <[email protected]>
Bump version to 2.0.2 & prepare for release

d4ac8f296e5727beae5fada6e1e2eaf01e65930e authored about 2 years ago by James Mead <[email protected]>
Fix regression in Mock#responds_like behaviour

The regression was inadvertently introduced in this commit [1] and
indirectly led to this issue ...

ba4d619ec6d6a27c9556a5708c14f2e86042792b authored about 2 years ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.1.

113b148c865ee45c9fd60a373f698039ba2631c3 authored about 2 years ago by James Mead <[email protected]>
Bump version to 2.0.1 & prepare for release

a6d6ac263f3a8ee138771f8ff825a485c88ebf8a authored about 2 years ago by James Mead <[email protected]>
ruby2_keywords is runtime dep not development dep

And so should be included as such in the gemspec; not in the Gemfile.

I've specified the '>= 0....

cdeb03562065525a09dda89b5c1592116a4cac0e authored about 2 years ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.0.

c5cf3249d9706f3470cbfcfd76e97b4bae87a3d0 authored about 2 years ago by James Mead <[email protected]>
Bump version to 2.0.0 & prepare for release

Note that the release notes from the v2.0.0.alpha & v2.0.0.alpha.1
pre-releases have been combin...

fcd5450bd742c8c61cff38d7e97903a919863bb3 authored about 2 years ago by James Mead <[email protected]>
Add README section re semantic versioning

Closes #577.

0075824697f5064d747ceb7d72ebb9d7d1e2dfca authored about 2 years ago by James Mead <[email protected]>
Improve docs for strict keyword argument matching

This addresses an ambiguity which was raised in this comment [1].

Since it's a bit subjective w...

10996795279980d6844461ea1f42512239cc1567 authored about 2 years ago by James Mead <[email protected]>
[skip ci] Add v1.16.0 into release docs

While strictly speaking the commits relating to these changes [1,2]
didn't make it into v2 relea...

a5e07fcc1b184089d719e6d706146ce832745324 authored about 2 years ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.0.alpha.1

e32e9e5f34db8611b3678b653b4b719eeefb9906 authored about 2 years ago by James Mead <[email protected]>
Bump version to 2.0.0.alpha.1 & prepare for release

90e1157d6b2b2b252ea7489dde713d80e1014854 authored about 2 years ago by James Mead <[email protected]>
Improve keyword argument deprecation warning

By including the source location of the stub definition.

This change is a necessarily a bit per...

77c0d4cc79fb5a8ad6f9f5059471f2a18509b435 authored about 2 years ago by James Mead <[email protected]>
Disable Style/Semicolon cop globally

This is useful when using `ExecutionPoint.current` to make tests more
robust.

8cd0b705a42e9dea8995d85e4a2419430915094a authored about 2 years ago by James Mead <[email protected]>
[skip ci] Update documentation for v2.0.0.alpha

9cd08be9628f3b7a95e2d52e84488b19775b4352 authored about 2 years ago by James Mead <[email protected]>
Bump version to 2.0.0.alpha & prepare for release

31d6887b4ad58ea7dd786f91e10f3a2c74edeb1c authored about 2 years ago by James Mead <[email protected]>
Remove deprecated Rails plugin file

1c617175018c9f8b00fd14eeb4395b325a674361 authored about 2 years ago by James Mead <[email protected]>
Improve docs for strict_keyword_argument_matching

* Make them more consistent with the docs for Expectation#with.
* Mention & explain deprecation ...

8d8f881d98a0f53fec12cd1a27be2260f8e086de authored about 2 years ago by James Mead <[email protected]>
Expand Expectation#with docs re keyword arguments

fed6808da2d02354a091fe25b9811dad09e785af authored about 2 years ago by James Mead <[email protected]>
Improve docs re using matchers in Expectation#with

da7237cd7ee63e14216065a632e43aa24fbf83e4 authored about 2 years ago by James Mead <[email protected]>
Fail fast when mock receives invocations in another test

This converts the deprecation warning introduced in
d66c2b501685fe827a2c5e2236475e78d8082c11 int...

cb054d59038429caf74d123cfaae77b28c957d67 authored about 2 years ago by James Mead <[email protected]>
Remove another redundant require statement

fa17b1148b6c160f92f40a5ede7e553fb1c864f2 authored about 2 years ago by James Mead <[email protected]>
Add missing require statement

73493761ad9eb495355c5e6a0c7e027cce343252 authored about 2 years ago by James Mead <[email protected]>
Remove redundant require statements

d82218a826587c94d58edb450689fdf0aa010748 authored about 2 years ago by James Mead <[email protected]>
Remove deprecated methods in Configuration

The following methods were deprecated in #421 and released in v1.10.0:

* Configuration.allow
* ...

e7ff7528bf0d7ddc78890a6a05bd87d928fac90f authored about 2 years ago by James Mead <[email protected]>
Remove optional reinstatement of v1.9 behaviour

In Mocha v1.10.0 some undocumented behaviour changed without any prior
deprecation warning.

* T...

1473ee25ff77a2bf218df6c11a68d62af61da2d0 authored about 2 years ago by James Mead <[email protected]>
Remove config option to reinstate deprecated behaviour

This removes Configuration#reinstate_undocumented_behaviour_from_v1_9
and its setter. The behavi...

1ed6dc722346eccbdc72756b1ece31dd9a2db11f authored about 2 years ago by James Mead <[email protected]>
Remove optional deprecated behaviour in Expectation

This removes the optional deprecated behaviour in Expectation#yields &
Expectation#multiple_yiel...

86434dd1f45ffce36e5ed46eb5924f5c2543970f authored about 2 years ago by James Mead <[email protected]>
Remove optional deprecated behaviour in API methods

This removes the optional deprecated behaviour in API#mock, API#stub &
API#stub_everything which...

b16524856f956b8c4c8206db781f17db0a21a998 authored about 2 years ago by James Mead <[email protected]>
Remove redundant deprecation disabling in MockTest

I'm not sure these calls to DeprecationDisabler.disable_deprecations
were ever necessary. Curren...

091fa623685e3fbb9d48643735aa2861b2d2b546 authored about 2 years ago by James Mead <[email protected]>
Add missing doc for API#stub parameter

This was missed in 472d54161fab9bbd093a8b8c6928a423cbad9897.

257b4cb4abb38a9e5b0730125b2ed4afb412f0c0 authored about 2 years ago by James Mead <[email protected]>
Remove deprecated mocha/setup.rb mechanism

Previously this was the recommended way to integrate Mocha with a test
framework. However, this ...

642a0ff4f3806ae0a625c50c14a6a39702735e51 authored about 2 years ago by James Mead <[email protected]>
Fail fast if test-unit/minitest integration fails

If someone is explicitly requiring "mocha/test_unit" or "mocha/minitest"
then the implication is...

f8215a166160a388ee4546914161542e3741d8a3 authored about 2 years ago by James Mead <[email protected]>
Drop support for older versions of minitest

Versions of minitest earlier than v3.3.0 are no longer supported.

Closes #541.

ca69dc9e13c538625df60ecb0a37c7da89340291 authored about 2 years ago by James Mead <[email protected]>
More consistent Test::Unit & Minitest integration

Use the value returned by Detection::TestUnit.testcase as the target of
the TestUnit::Adapter mo...

27dd3817ce1152ab1d93eed680e12b55c2f09fab authored about 2 years ago by James Mead <[email protected]>
Drop support for older versions of test-unit

Gem versions of test-unit earlier than v2.5.1 and versions of test-unit
from the Ruby v1.8 stand...

969f48459eb6ebb2e059da3d8a5198bba677b0fc authored about 2 years ago by James Mead <[email protected]>
Deprecate hash args that don't strictly match

This will generate a deprecation warning if Ruby >= v2.7,
Configuration#strict_keyword_argument_...

981c31be090a4676822527e525e8f45ac2fbaf5f authored about 2 years ago by James Mead <[email protected]>
Improve test coverage of PositionalOrKeywordHash

When strict_keyword_argument_matching configuration option is not set.

c294fe707b79d256dd1880baa141f9ea9471bd01 authored about 2 years ago by James Mead <[email protected]>
Support strict keyword argument matching

Closes #562.

This introduces a new `strict_keyword_argument_matching` configuration
option. Thi...

2e72eb5b23f55142f4eab182817adbf8aaaa35b1 authored about 2 years ago by James Mead <[email protected]>
Improve inspection of positional & keyword Hashes

With the introduction of strict keyword matching, we're explicitly
distinguishing between positi...

ef0fa0c9894f31faae260d4656796a2940bb09e5 authored about 2 years ago by James Mead <[email protected]>
Always wrap Hash inspection in braces

Previously in the description of an invocation or of a parameter
matcher, a single Hash argument...

e6c8c27ae79970f15c4c298e0cb8d2e7d07ee13a authored about 2 years ago by James Mead <[email protected]>
Implement optional strict keyword arg matching

When the strict keyword argument option is enabled, an expectation
expecting keyword arguments (...

336ab3bd860cc7583cc8eec9ea57e465c39b8ebf authored about 2 years ago by wasabigeek <[email protected]>
Mark methods passing keyword args via args splat

This marks Expectation#with, Mock#method_missing, and the method defined
by StubbedMethod#define...

636d4633d2f91a02450f653deb4241d7712a0532 authored about 2 years ago by wasabigeek <[email protected]>
Add strict keyword arg matching config option

This option doesn't currently do anything, but in a subsequent commit it
will determine whether ...

7d534d0c0eb4fc0685639c834109b7e18cd37ba2 authored about 2 years ago by wasabigeek <[email protected]>
Add tests to characterize inspection of Hashes

We're planning to change how this works once we're explicitly
distinguishing between keyword and...

a3defd5229e47f3c27554c3b061e38b5aafcd8f3 authored about 2 years ago by Nicholas Koh <[email protected]>
Add acceptance tests for keyword arg matching

This is to better characterize the existing behaviour. It should also
make it clearer what chang...

6f9e43d2091620ce04e2da456c7b727994485e19 authored about 2 years ago by wasabigeek <[email protected]>
Improve test runner assertions - failure vs error

Make more of a distinction between test failures and errors. Explicitly
assert for what we are e...

eec7200a2cc5fc11a525d0e5156674c7680d36ff authored about 2 years ago by James Mead <[email protected]>
Remove unused arg for HashMethods#mocha_inspect

This was introduced in this commit [1] apparently as a precursor to the
addition of ParameterMat...

4f59e27f06dad87d86163ad680db91b0accf0984 authored about 2 years ago by James Mead <[email protected]>
Multi-line rubocop disable in Mock#method_missing

I think this makes the code more readable.

af2194c4f4465200fd07fd078f2dbefd9f712360 authored over 2 years ago by James Mead <[email protected]>
Remove support for Ruby v1.9

Closes #552.

26c4ae1ecd1057751685a5474932d05701a2c294 authored over 2 years ago by James Mead <[email protected]>
Rename remove_new_method tests

ddd9b0c711b936871c305eff216927696fc5e9b4 authored over 2 years ago by wasabigeek <[email protected]>
Remove restore_original_method

2e77d57c49f9ed995adeb039ea769e2b4bb07d20 authored over 2 years ago by wasabigeek <[email protected]>
Remove orphaned flow from restore_original_method

a47ff4dd4ec53187ccf2cfbec3c0ff3fd57ce6dd authored over 2 years ago by wasabigeek <[email protected]>
Remove orphaned flow from hide_original_method

0cb193a303a3a2d2b57a7bba129152fd67b7b413 authored over 2 years ago by wasabigeek <[email protected]>
Replace RUBY_V2_PLUS with true in StubbedMethod

30ac58936999771cd29ed11852dc084ab8053b95 authored over 2 years ago by wasabigeek <[email protected]>
Set required Ruby > 2.0

f2819c4095a5c8c656c1b75756d4ee227074549d authored over 2 years ago by wasabigeek <[email protected]>
Remove RUBY_V2_PLUS

f38be1d463c385f750fd9ca8b635fd57efcde36b authored over 2 years ago by wasabigeek <[email protected]>