Skip to content
This repository was archived by the owner on Nov 30, 2024. It is now read-only.

Commit 2d82918

Browse files
authored
Merge pull request #2824 from rspec/update-common-plaintext-files-2020-12-26-for-4-0-dev
Updates from rspec-dev (2020-12-26)
2 parents b5a4672 + d6068a2 commit 2d82918

File tree

6 files changed

+57
-16
lines changed

6 files changed

+57
-16
lines changed

.github/FUNDING.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
# This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
1+
# This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
22
# DO NOT modify it by hand as your changes will get lost the next time it is generated.
33

4-
github: [JonRowe]
4+
github: [JonRowe, benoittgt]
55
open_collective: rspec

BUILD_DETAIL.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!---
2-
This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
2+
This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
33
DO NOT modify it by hand as your changes will get lost the next time it is generated.
44
-->
55

@@ -97,10 +97,11 @@ $ bundle exec yard doc --no-cache
9797
$ bin/yard doc --no-cache
9898
```
9999

100-
## Rubocop
100+
## RuboCop
101101

102-
We use [Rubocop](https://github.com/bbatsov/rubocop) to enforce style conventions on the project so
103-
that the code has stylistic consistency throughout. Run with:
102+
We use [RuboCop](https://github.com/rubocop-hq/rubocop) to enforce style
103+
conventions on the project so that the code has stylistic consistency
104+
throughout. Run with:
104105

105106
```
106107
$ bundle exec rubocop lib
@@ -110,9 +111,9 @@ $ bundle exec rubocop lib
110111
$ bin/rubocop lib
111112
```
112113

113-
Our Rubocop configuration is a work-in-progress, so if you get a failure
114-
due to a Rubocop default, feel free to ask about changing the
115-
configuration. Otherwise, you'll need to address the Rubocop failure,
114+
Our RuboCop configuration is a work-in-progress, so if you get a failure
115+
due to a RuboCop default, feel free to ask about changing the
116+
configuration. Otherwise, you'll need to address the RuboCop failure,
116117
or, as a measure of last resort, by wrapping the offending code in
117118
comments like `# rubocop:disable SomeCheck` and `# rubocop:enable SomeCheck`.
118119

@@ -146,4 +147,3 @@ build for another repo, so our CI build includes a spec that runs the
146147
spec suite of each of the _other_ project repos. Note that we only run
147148
the spec suite, not the full build, of the other projects, as the spec
148149
suite runs very quickly compared to the full build.
149-

CODE_OF_CONDUCT.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!---
2-
This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
2+
This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
33
DO NOT modify it by hand as your changes will get lost the next time it is generated.
44
-->
55

CONTRIBUTING.md

Lines changed: 43 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!---
2-
This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
2+
This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
33
DO NOT modify it by hand as your changes will get lost the next time it is generated.
44
-->
55

@@ -42,3 +42,45 @@ test case. To make this process easier, we have prepared one basic
4242
Maintenance branches are how we manage the different supported point releases
4343
of RSpec. As such, while they might look like good candidates to merge into
4444
main, please do not open pull requests to merge them.
45+
46+
## Working on multiple RSpec gems at the same time
47+
48+
RSpec is composed of multiple gems (`rspec-core`, `rspec-mocks`, etc). Sometimes you have
49+
to work on a combination of them at the same time. When submitting your code for review,
50+
we ask that you get a passing build (green CI). If you are working across the repositories,
51+
please add a commit that temporarily pins your PR to the right branch of the other repository
52+
you depend on. For example, if we wanted a change in `rspec-expectations` that relied on a
53+
change for on `rspec-mocks`. We add a commit with the title:
54+
55+
>[WIP] Use rspec-mocks with "custom-failure-message" branch
56+
57+
And content:
58+
59+
```diff
60+
diff --git a/Gemfile b/Gemfile
61+
62+
-%w[rspec rspec-core rspec-mocks rspec-support].each do |lib|
63+
+%w[rspec rspec-core rspec-support].each do |lib|
64+
library_path = File.expand_path("../../#{lib}", __FILE__)
65+
if File.exist?(library_path) && !ENV['USE_GIT_REPOS']
66+
gem lib, :path => library_path
67+
@@ -11,6 +11,7 @@ branch = File.read(File.expand_path("../maintenance-branch", __FILE__)).chomp
68+
gem lib, :git => "https://github.com/rspec/#{lib}.git", :branch => branch
69+
end
70+
end
71+
+gem 'rspec-mocks', :git => "https://github.com/rspec/rspec-mocks.git", :branch => "custom-failure-message"
72+
```
73+
74+
In general the process is:
75+
1. Create PRs explaining what you are trying to achieve.
76+
2. Pin the repositories to each other.
77+
3. Check they pass (go green).
78+
4. Await review if appropriate.
79+
5. Remove the commit from step 2. We will merge ignoring the failure.
80+
6. Remove the commit from the other, check it passes with the other commit now on `main`.
81+
7. Merge the other.
82+
8. We will trigger builds for the `main` branch of affected repositories to check if everything is in order.
83+
84+
Steps 5-8 should happen continuously (e.g. one after another but within a short timespan)
85+
so that we don't leave a broken main around. It is important to triage that build process
86+
and revert if necessary.

DEVELOPMENT.md

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!---
2-
This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
2+
This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
33
DO NOT modify it by hand as your changes will get lost the next time it is generated.
44
-->
55

@@ -108,7 +108,7 @@ Here's a short, non-exhaustive checklist of things we typically ask contributors
108108
- [ ] New behavior is covered by tests and all tests are passing.
109109
- [ ] No Ruby warnings are issued by your changes.
110110
- [ ] Documentation reflects changes and renders as intended.
111-
- [ ] Rubocop passes (e.g. `bundle exec rubocop lib`).
111+
- [ ] RuboCop passes (e.g. `bundle exec rubocop lib`).
112112
- [ ] Commits are squashed into a reasonable number of logical changesets that tell an easy-to-follow story.
113113
- [ ] No changelog entry is necessary (we'll add it as part of the merge process!)
114114

@@ -129,4 +129,3 @@ $ bin/yard server --reload
129129
```
130130

131131
Then navigate to `localhost:8808` to view the rendered docs.
132-

REPORT_TEMPLATE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<!---
2-
This file was generated on 2019-12-05T21:32:23+00:00 from the rspec-dev repo.
2+
This file was generated on 2020-12-26T20:29:41+00:00 from the rspec-dev repo.
33
DO NOT modify it by hand as your changes will get lost the next time it is generated.
44
-->
55

0 commit comments

Comments
 (0)