Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RSpec: config.disable_monkey_patching! #211

Merged
1 commit merged into from
Dec 10, 2018

Conversation

olleolleolle
Copy link
Member

@olleolleolle olleolleolle commented Dec 10, 2018

This PR configures RSpec to avoid some now-unnecessary metaprogramming.

See http://rspec.info/documentation/3.8/rspec-core/RSpec/Core/Configuration.html#disable_monkey_patching!-instance_method

Enables zero monkey patching mode for RSpec. It removes monkey patching of the top-level DSL methods (describe, shared_examples_for, etc) onto main and Module, instead requiring you to prefix these methods with RSpec.. It enables expect-only syntax for rspec-mocks and rspec-expectations. It simply disables monkey patching on whatever pieces of RSpec the user is using.

Copy link
Member

@bronzdoc bronzdoc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTm

@bronzdoc
Copy link
Member

@bundlerbot r+

ghost pushed a commit that referenced this pull request Dec 10, 2018
211: RSpec: config.disable_monkey_patching! r=bronzdoc a=olleolleolle

This PR configures RSpec to avoid some now-unnecessary metaprogramming.

See http://rspec.info/documentation/3.8/rspec-core/RSpec/Core/Configuration.html#disable_monkey_patching!-instance_method

> Enables zero monkey patching mode for RSpec. It removes monkey patching of the top-level DSL methods (describe, shared_examples_for, etc) onto main and Module, instead requiring you to prefix these methods with RSpec.. It enables expect-only syntax for rspec-mocks and rspec-expectations. It simply disables monkey patching on whatever pieces of RSpec the user is using.





Co-authored-by: Olle Jonsson <olle.jonsson@gmail.com>
@ghost
Copy link

ghost commented Dec 10, 2018

Build succeeded

@ghost ghost merged commit ed8a6f6 into rubygems:master Dec 10, 2018
@olleolleolle olleolleolle deleted the fix/rspec-no-monkey-patch-mode branch December 10, 2018 18:17
phanle pushed a commit to Gusto/gemstash-public-fork-archive that referenced this pull request Aug 12, 2019
200: Update rake requirement from ~> 10.0 to ~> 12.3 r=bronzdoc a=dependabot[bot]

Updates the requirements on [rake](https://github.com/ruby/rake) to permit the latest version.
<details>
<summary>Changelog</summary>

*Sourced from [rake's changelog](https://github.com/ruby/rake/blob/master/History.rdoc).*

> === 12.3.1
> 
> ==== Bug fixes
> 
> * Support did_you_mean >= v1.2.0 which has a breaking change on formatters.
>   Pull request [rubygems#262](https://github-redirect.dependabot.com/ruby/rake/issues/262) by FUJI Goro.
> 
> ==== Enhancements:
> 
> * Don't run task if it depends on already invoked but failed task.
>   Pull request [rubygems#252](https://github-redirect.dependabot.com/ruby/rake/issues/252) by Gonzalo Rodriguez.
> * Make space trimming consistent for all task arguments.
>   Pull request [rubygems#259](https://github-redirect.dependabot.com/ruby/rake/issues/259) by Gonzalo Rodriguez.
> * Removes duplicated inclusion of Rake::DSL in tests.
>   Pull request [rubygems#254](https://github-redirect.dependabot.com/ruby/rake/issues/254) by Gonzalo Rodriguez.
> * Re-raise a LoadError that didn't come from require in the test loader.
>   Pull request [rubygems#250](https://github-redirect.dependabot.com/ruby/rake/issues/250) by Dylan Thacker-Smith.
> 
> === 12.3.0
> 
> ==== Compatibility Changes
> 
> * Bump `required_ruby_version` to Ruby 2.0.0. Rake has already
>   removed support for Ruby 1.9.x.
> 
> ==== Enhancements:
> 
> * Support `test-bundled-gems` task on ruby core.
> 
> === 12.2.1
> 
> ==== Bug fixes
> 
> * Fixed to break Capistrano::Application on capistrano3.
> 
> === 12.2.0
> 
> ==== Enhancements:
> 
> * Make rake easier to use as a library
>   Pull request [rubygems#211](https://github-redirect.dependabot.com/ruby/rake/issues/211) by [**drbrain**](https://github.com/drbrain)
> * Fix quadratic performance in FileTask#out_of_date?
>   Pull request [rubygems#224](https://github-redirect.dependabot.com/ruby/rake/issues/224) by [**doudou**](https://github.com/doudou)
> * Clarify output when printing nested exception traces
>   Pull request [rubygems#232](https://github-redirect.dependabot.com/ruby/rake/issues/232) by [**urbanautomaton**](https://github.com/urbanautomaton)
> 
> ==== Bug fixes
> 
> * Account for a file that match 2 or more patterns.
>   Pull request [rubygems#231](https://github-redirect.dependabot.com/ruby/rake/issues/231) by [**styd**](https://github.com/styd)
></table> ... (truncated)
</details>
<details>
<summary>Commits</summary>

- See full diff in [compare view](https://github.com/ruby/rake/commits/v12.3.1)
</details>
<br />

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

---

**Note:** This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit.

You can always request more updates by clicking `Bump now` in your [Dependabot dashboard](https://app.dependabot.com).

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot ignore this [patch|minor|major] version` will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme

Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com):
- Update frequency (including time of day and day of week)
- Automerge options (never/patch/minor, and dev/runtime dependencies)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)

Finally, you can contact us by mentioning @dependabot.

</details>

Co-authored-by: dependabot[bot] <support@dependabot.com>
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants