rspec-core 3.0.4 → 3.12.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- checksums.yaml.gz.sig +0 -0
- data/.document +1 -1
- data/.yardopts +2 -1
- data/Changelog.md +888 -2
- data/{License.txt → LICENSE.md} +6 -5
- data/README.md +165 -24
- data/lib/rspec/autorun.rb +1 -0
- data/lib/rspec/core/backtrace_formatter.rb +19 -20
- data/lib/rspec/core/bisect/coordinator.rb +62 -0
- data/lib/rspec/core/bisect/example_minimizer.rb +173 -0
- data/lib/rspec/core/bisect/fork_runner.rb +138 -0
- data/lib/rspec/core/bisect/server.rb +61 -0
- data/lib/rspec/core/bisect/shell_command.rb +126 -0
- data/lib/rspec/core/bisect/shell_runner.rb +73 -0
- data/lib/rspec/core/bisect/utilities.rb +69 -0
- data/lib/rspec/core/configuration.rb +1287 -246
- data/lib/rspec/core/configuration_options.rb +95 -35
- data/lib/rspec/core/did_you_mean.rb +46 -0
- data/lib/rspec/core/drb.rb +21 -12
- data/lib/rspec/core/dsl.rb +10 -6
- data/lib/rspec/core/example.rb +305 -113
- data/lib/rspec/core/example_group.rb +431 -223
- data/lib/rspec/core/example_status_persister.rb +235 -0
- data/lib/rspec/core/filter_manager.rb +86 -115
- data/lib/rspec/core/flat_map.rb +6 -4
- data/lib/rspec/core/formatters/base_bisect_formatter.rb +45 -0
- data/lib/rspec/core/formatters/base_formatter.rb +14 -116
- data/lib/rspec/core/formatters/base_text_formatter.rb +18 -21
- data/lib/rspec/core/formatters/bisect_drb_formatter.rb +29 -0
- data/lib/rspec/core/formatters/bisect_progress_formatter.rb +157 -0
- data/lib/rspec/core/formatters/console_codes.rb +29 -18
- data/lib/rspec/core/formatters/deprecation_formatter.rb +16 -16
- data/lib/rspec/core/formatters/documentation_formatter.rb +49 -16
- data/lib/rspec/core/formatters/exception_presenter.rb +525 -0
- data/lib/rspec/core/formatters/failure_list_formatter.rb +23 -0
- data/lib/rspec/core/formatters/fallback_message_formatter.rb +28 -0
- data/lib/rspec/core/formatters/helpers.rb +45 -15
- data/lib/rspec/core/formatters/html_formatter.rb +33 -28
- data/lib/rspec/core/formatters/html_printer.rb +30 -20
- data/lib/rspec/core/formatters/html_snippet_extractor.rb +120 -0
- data/lib/rspec/core/formatters/json_formatter.rb +18 -9
- data/lib/rspec/core/formatters/profile_formatter.rb +10 -9
- data/lib/rspec/core/formatters/progress_formatter.rb +5 -4
- data/lib/rspec/core/formatters/protocol.rb +182 -0
- data/lib/rspec/core/formatters/snippet_extractor.rb +113 -82
- data/lib/rspec/core/formatters/syntax_highlighter.rb +91 -0
- data/lib/rspec/core/formatters.rb +81 -41
- data/lib/rspec/core/hooks.rb +314 -244
- data/lib/rspec/core/invocations.rb +87 -0
- data/lib/rspec/core/memoized_helpers.rb +161 -51
- data/lib/rspec/core/metadata.rb +132 -61
- data/lib/rspec/core/metadata_filter.rb +224 -64
- data/lib/rspec/core/minitest_assertions_adapter.rb +6 -3
- data/lib/rspec/core/mocking_adapters/flexmock.rb +4 -2
- data/lib/rspec/core/mocking_adapters/mocha.rb +11 -9
- data/lib/rspec/core/mocking_adapters/null.rb +2 -0
- data/lib/rspec/core/mocking_adapters/rr.rb +3 -1
- data/lib/rspec/core/mocking_adapters/rspec.rb +3 -1
- data/lib/rspec/core/notifications.rb +192 -206
- data/lib/rspec/core/option_parser.rb +174 -69
- data/lib/rspec/core/ordering.rb +48 -35
- data/lib/rspec/core/output_wrapper.rb +29 -0
- data/lib/rspec/core/pending.rb +25 -33
- data/lib/rspec/core/profiler.rb +34 -0
- data/lib/rspec/core/project_initializer/.rspec +0 -2
- data/lib/rspec/core/project_initializer/spec/spec_helper.rb +59 -39
- data/lib/rspec/core/project_initializer.rb +5 -3
- data/lib/rspec/core/rake_task.rb +99 -55
- data/lib/rspec/core/reporter.rb +128 -15
- data/lib/rspec/core/ruby_project.rb +14 -6
- data/lib/rspec/core/runner.rb +96 -45
- data/lib/rspec/core/sandbox.rb +37 -0
- data/lib/rspec/core/set.rb +54 -0
- data/lib/rspec/core/shared_example_group.rb +133 -43
- data/lib/rspec/core/shell_escape.rb +49 -0
- data/lib/rspec/core/test_unit_assertions_adapter.rb +4 -4
- data/lib/rspec/core/version.rb +1 -1
- data/lib/rspec/core/warnings.rb +6 -6
- data/lib/rspec/core/world.rb +172 -68
- data/lib/rspec/core.rb +66 -21
- data.tar.gz.sig +0 -0
- metadata +93 -69
- metadata.gz.sig +0 -0
- data/lib/rspec/core/backport_random.rb +0 -336
data/Changelog.md
CHANGED
|
@@ -1,3 +1,877 @@
|
|
|
1
|
+
### Development
|
|
2
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.12.2...3-12-maintenance)
|
|
3
|
+
|
|
4
|
+
### 3.12.2 / 2023-04-18
|
|
5
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.12.1...v3.12.2)
|
|
6
|
+
|
|
7
|
+
Bug fixes:
|
|
8
|
+
|
|
9
|
+
* Remove link to outdated documentation in generated output. (Jon Rowe, #3035)
|
|
10
|
+
|
|
11
|
+
### 3.12.1 / 2023-02-03
|
|
12
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.12.0...v3.12.1)
|
|
13
|
+
|
|
14
|
+
Bug fixes:
|
|
15
|
+
|
|
16
|
+
* Prevent multiple calls to `extra_failure_lines` from adding additional whitespace
|
|
17
|
+
around them when the lines already contain whitespace. (Jon Rowe, #3006)
|
|
18
|
+
|
|
19
|
+
### 3.12.0 / 2022-10-26
|
|
20
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.11.0...v3.12.0)
|
|
21
|
+
|
|
22
|
+
* No changes, released to support other gems.
|
|
23
|
+
|
|
24
|
+
### 3.11.0 / 2022-02-09
|
|
25
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.10.2...v3.11.0)
|
|
26
|
+
|
|
27
|
+
Enhancements:
|
|
28
|
+
|
|
29
|
+
* Improve pluralisation of words ending with `s` (like process). (Joshua Pinter, #2779)
|
|
30
|
+
* Add ordering by file modification time (most recent first). (Matheus Richard, #2778)
|
|
31
|
+
* Add `to_s` to reserved names for #let and #subject. (Nick Flückiger, #2886)
|
|
32
|
+
* Introduce `RSpec.current_scope` to expose the current scope in which
|
|
33
|
+
RSpec is executing. e.g. `:before_example_hook`, `:example` etc. (@odinhb, #2895)
|
|
34
|
+
* Add named bold colours as options for custom colours. (#2913, #2914)
|
|
35
|
+
* Warn when (but not prevent) a `SystemExit` occurs. (Jared Beck, #2926)
|
|
36
|
+
|
|
37
|
+
### 3.10.2 / 2022-01-27
|
|
38
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.10.1...v3.10.2)
|
|
39
|
+
|
|
40
|
+
Bug fixes:
|
|
41
|
+
|
|
42
|
+
* Ensure bisect communication uses consistent encoding. (Mike Jarema, #2852)
|
|
43
|
+
* Fix exception presenter when the root cause exception has nil backtrace.
|
|
44
|
+
(Zinovyev Ivan, #2903)
|
|
45
|
+
* Fix `inspect` output of `RSpec::Core::Example::Procsy` to namespace correctly.
|
|
46
|
+
(Keiko Kaneko, #2915)
|
|
47
|
+
* Ensure formatters not exposing `#output` will not crash duplicate check.
|
|
48
|
+
(@niceking, #2916)
|
|
49
|
+
|
|
50
|
+
### 3.10.1 / 2020-12-27
|
|
51
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.10.0...v3.10.1)
|
|
52
|
+
|
|
53
|
+
Bug fixes:
|
|
54
|
+
|
|
55
|
+
* RSpec warning output was missing deprecations from Ruby, these are now included.
|
|
56
|
+
(Jon Rowe, #2811)
|
|
57
|
+
|
|
58
|
+
### 3.10.0 / 2020-10-30
|
|
59
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.9.3...v3.10.0)
|
|
60
|
+
|
|
61
|
+
Enhancements:
|
|
62
|
+
|
|
63
|
+
* Memoize `RSpec::Core::Formatters::ExceptionPresenter#exception_lines` to improve performance
|
|
64
|
+
with slow exception messages. (Maxime Lapointe, #2743)
|
|
65
|
+
* Add configuration for an error exit code (to disambiguate errored builds from failed builds
|
|
66
|
+
by exit status). (Dana Sherson, #2749)
|
|
67
|
+
|
|
68
|
+
### 3.9.3 / 2020-09-30
|
|
69
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.9.2...v3.9.3)
|
|
70
|
+
|
|
71
|
+
Bug Fixes:
|
|
72
|
+
|
|
73
|
+
* Declare `ruby2_keywords` on `method_missing` for other gems. (Jon Rowe, #2731)
|
|
74
|
+
* Ensure custom error codes are returned from bisect runs. (Jon Rowe, #2732)
|
|
75
|
+
* Ensure `RSpec::Core::Configuration` predicate config methods return booleans.
|
|
76
|
+
(Marc-André Lafortune, #2736)
|
|
77
|
+
* Prevent `rspec --bisect` from generating zombie processes while executing
|
|
78
|
+
bisect runs. (Benoit Tigeot, Jon Rowe, #2739)
|
|
79
|
+
* Predicates for pending examples, (in `RSpec::Core::Example`, `#pending?`, `#skipped?` and
|
|
80
|
+
`#pending_fixed?`) now return boolean values rather than truthy values.
|
|
81
|
+
(Marc-André Lafortune, #2756, #2758)
|
|
82
|
+
* Exceptions which have a message which cannot be cast to a string will no longer
|
|
83
|
+
cause a crash. (Jon Rowe, #2761)
|
|
84
|
+
|
|
85
|
+
### 3.9.2 / 2020-05-02
|
|
86
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.9.1...v3.9.2)
|
|
87
|
+
|
|
88
|
+
Bug Fixes:
|
|
89
|
+
|
|
90
|
+
* Emit a warning when `around` hook is used with `:context` scope
|
|
91
|
+
(Phil Pirozhkov, #2687)
|
|
92
|
+
* Prevent invalid implementations of `Exception#cause` from being treated as a
|
|
93
|
+
valid cause (and causing strange errors) in `RSpec::Core::Formatters::ExceptionPresenter`.
|
|
94
|
+
(Jon Rowe, #2703)
|
|
95
|
+
* Correctly detect patterns when `rspec_opts` is an array in `RSpec::Core::RakeTask`.
|
|
96
|
+
(Marc-André Lafortune, #2704)
|
|
97
|
+
* Make `RSpec.clear_examples` reset example counts for example groups. This fixes
|
|
98
|
+
an issue with re-running specs not matching ids. (Agis Anastasopoulos, #2723)
|
|
99
|
+
|
|
100
|
+
### 3.9.1 / 2019-12-28
|
|
101
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.9.0...v3.9.1)
|
|
102
|
+
|
|
103
|
+
Bug Fixes:
|
|
104
|
+
|
|
105
|
+
* Prevent bisect command from blocking when number of specs exceeds file
|
|
106
|
+
descriptor limit on OSX or Linux. (Benoit Tigeot, #2669)
|
|
107
|
+
* Prevent warnings being issued on Ruby 2.7.0. (Jon Rowe, #2680)
|
|
108
|
+
|
|
109
|
+
### 3.9.0 / 2019-10-07
|
|
110
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.8.2...v3.9.0)
|
|
111
|
+
|
|
112
|
+
Enhancements:
|
|
113
|
+
|
|
114
|
+
* Improve the handling of errors during loading support files, if a file
|
|
115
|
+
errors before loading specs, RSpec will now skip loading the specs.
|
|
116
|
+
(David Rodríguez, #2568)
|
|
117
|
+
* Add support for --example-matches to run examples by regular expression.
|
|
118
|
+
(Sam Joseph, Matt Rider, @okothkongo1, #2586)
|
|
119
|
+
* Add `did_you_mean` suggestions for file names encountering a `LoadError`
|
|
120
|
+
outside of examples. (@obromios, #2601)
|
|
121
|
+
* Add a minimalist quick fix style formatter, only outputs failures as
|
|
122
|
+
`file:line:message`. (Romain Tartière, #2614)
|
|
123
|
+
* Convert string number values to integer when used for `RSpec::Configuration#fail_fast`
|
|
124
|
+
(Viktor Fonic, #2634)
|
|
125
|
+
* Issue warning when invalid values are used for `RSpec::Configuration#fail_fast`
|
|
126
|
+
(Viktor Fonic, #2634)
|
|
127
|
+
* Add support for running the Rake task in a clean environment.
|
|
128
|
+
(Jon Rowe, #2632)
|
|
129
|
+
* Indent messages by there example group / example in the documentation formatter.
|
|
130
|
+
(Samuel Williams, #2649)
|
|
131
|
+
|
|
132
|
+
### 3.8.2 / 2019-06-29
|
|
133
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.8.1...v3.8.2)
|
|
134
|
+
|
|
135
|
+
Bug Fixes:
|
|
136
|
+
|
|
137
|
+
* Fix `config.define_derived_metadata` so that cascades are not triggered
|
|
138
|
+
until metadata has been assigned to the example or example group
|
|
139
|
+
(Myron Marston, #2635).
|
|
140
|
+
|
|
141
|
+
### 3.8.1 / 2019-06-13
|
|
142
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.8.0...v3.8.1)
|
|
143
|
+
|
|
144
|
+
Bug Fixes:
|
|
145
|
+
|
|
146
|
+
* Handle RSpec description(s) with japanese chars in CP932 encoded files.
|
|
147
|
+
(Benoit Tigeot, #2575)
|
|
148
|
+
* When defining `let` methods that overwrite an existing method, prevent
|
|
149
|
+
a warning being issued by removing the old definition. (Jon Rowe, #2593)
|
|
150
|
+
* Prevent warning on Ruby 2.6.0-rc1 (Keiji Yoshimi, #2582)
|
|
151
|
+
* Fix `config.define_derived_metadata` so that it supports cascades.
|
|
152
|
+
(Myron Marston, #2630).
|
|
153
|
+
|
|
154
|
+
### 3.8.0 / 2018-08-04
|
|
155
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.7.1...v3.8.0)
|
|
156
|
+
|
|
157
|
+
Enhancements:
|
|
158
|
+
|
|
159
|
+
* Improve shell escaping used by `RSpec::Core::RakeTask` and `--bisect` so
|
|
160
|
+
that it works on `Pathname` objects. (Andrew Vit, #2479)
|
|
161
|
+
* Nicely format errors encountered while loading files specified
|
|
162
|
+
by `--require` option. (Myron Marston, #2504)
|
|
163
|
+
* Significantly improve the performance of `--bisect` on platforms that
|
|
164
|
+
support forking by replacing the shell-based runner with one that uses
|
|
165
|
+
forking so that RSpec and the application environment can be booted only
|
|
166
|
+
once, instead of once per spec run. (Myron Marston, #2511)
|
|
167
|
+
* Provide a configuration API to pick which bisect runner is used for
|
|
168
|
+
`--bisect`. Pick a runner via `config.bisect_runner = :shell` or
|
|
169
|
+
`config.bisect_runner = :fork` in a file loaded by a `--require`
|
|
170
|
+
option passed at the command line or set in `.rspec`. (Myron Marston, #2511)
|
|
171
|
+
* Support the [XDG Base Directory
|
|
172
|
+
Specification](https://specifications.freedesktop.org/basedir-spec/latest/)
|
|
173
|
+
for the global options file. `~/.rspec` is still supported when no
|
|
174
|
+
options file is found in `$XDG_CONFIG_HOME/rspec/options` (Magnus Bergmark, #2538)
|
|
175
|
+
* Extract `RSpec.world.prepare_example_filtering` that sets up the
|
|
176
|
+
example filtering for custom RSpec runners. (Oleg Pudeyev, #2552)
|
|
177
|
+
|
|
178
|
+
Bug Fixes:
|
|
179
|
+
|
|
180
|
+
* Prevent an `ArgumentError` when truncating backtraces with two identical
|
|
181
|
+
backtraces. (Systho, #2515, Benoit Tigeot, #2539)
|
|
182
|
+
|
|
183
|
+
### 3.7.1 / 2018-01-02
|
|
184
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.7.0...v3.7.1)
|
|
185
|
+
|
|
186
|
+
Bug Fixes:
|
|
187
|
+
|
|
188
|
+
* Work around duplicate config hook regression introduced
|
|
189
|
+
by Ruby 2.5's lazy proc allocation. (Myron Marston, #2497)
|
|
190
|
+
|
|
191
|
+
### 3.7.0 / 2017-10-17
|
|
192
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.6.0...v3.7.0)
|
|
193
|
+
|
|
194
|
+
Enhancements:
|
|
195
|
+
|
|
196
|
+
* Add `-n` alias for `--next-failure`. (Ian Ker-Seymer, #2434)
|
|
197
|
+
* Improve compatibility with `--enable-frozen-string-literal` option
|
|
198
|
+
on Ruby 2.3+. (Pat Allan, #2425, #2427, #2437)
|
|
199
|
+
* Do not run `:context` hooks for example groups that have been skipped.
|
|
200
|
+
(Devon Estes, #2442)
|
|
201
|
+
* Add `errors_outside_of_examples_count` to the JSON formatter.
|
|
202
|
+
(Takeshi Arabiki, #2448)
|
|
203
|
+
|
|
204
|
+
Bug Fixes:
|
|
205
|
+
|
|
206
|
+
* Improve compatibility with frozen string literal flag. (#2425, Pat Allan)
|
|
207
|
+
|
|
208
|
+
### 3.6.0 / 2017-05-04
|
|
209
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.6.0.beta2...v3.6.0)
|
|
210
|
+
|
|
211
|
+
Enhancements:
|
|
212
|
+
|
|
213
|
+
* Add seed information to JSON formatter output. (#2388, Mitsutaka Mimura)
|
|
214
|
+
* Include example id in the JSON formatter output. (#2369, Xavier Shay)
|
|
215
|
+
* Respect changes to `config.output_stream` after formatters have been
|
|
216
|
+
setup. (#2401, #2419, Ilya Lavrov)
|
|
217
|
+
|
|
218
|
+
Bug Fixes:
|
|
219
|
+
|
|
220
|
+
* Delay formatter loading until the last minute to allow accessing the reporter
|
|
221
|
+
without triggering formatter setup. (Jon Rowe, #2243)
|
|
222
|
+
* Ensure context hook failures running before an example can access the
|
|
223
|
+
reporter. (Jon Jensen, #2387)
|
|
224
|
+
* Multiple fixes to allow using the runner multiple times within the same
|
|
225
|
+
process: `RSpec.clear_examples` resets the formatter and no longer clears
|
|
226
|
+
shared examples, and streams can be used across multiple runs rather than
|
|
227
|
+
being closed after the first. (#2368, Xavier Shay)
|
|
228
|
+
* Prevent unexpected `example_group_finished` notifications causing an error.
|
|
229
|
+
(#2396, VTJamie)
|
|
230
|
+
* Fix bugs where `config.when_first_matching_example_defined` hooks would fire
|
|
231
|
+
multiple times in some cases. (Yuji Nakayama, #2400)
|
|
232
|
+
* Default `last_run_status` to "unknown" when the `status` field in the
|
|
233
|
+
persistence file contains an unrecognized value. (#2360, matrinox)
|
|
234
|
+
* Prevent `let` from defining an `initialize` method. (#2414, Jon Rowe)
|
|
235
|
+
|
|
236
|
+
### 3.6.0.beta2 / 2016-12-12
|
|
237
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.6.0.beta1...v3.6.0.beta2)
|
|
238
|
+
|
|
239
|
+
Enhancements:
|
|
240
|
+
|
|
241
|
+
* Include count of errors occurring outside examples in default summaries.
|
|
242
|
+
(#2351, Jon Rowe)
|
|
243
|
+
* Warn when including shared example groups recursively. (#2356, Jon Rowe)
|
|
244
|
+
* Improve failure snippet syntax highlighting with CodeRay to highlight
|
|
245
|
+
RSpec "keywords" like `expect`. (#2358, Myron Marston)
|
|
246
|
+
|
|
247
|
+
### 3.6.0.beta1 / 2016-10-09
|
|
248
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.4...v3.6.0.beta1)
|
|
249
|
+
|
|
250
|
+
Enhancements:
|
|
251
|
+
|
|
252
|
+
* Warn when duplicate shared examples definitions are loaded due to being
|
|
253
|
+
defined in files matching the spec pattern (e.g. `_spec.rb`) (#2278, Devon Estes)
|
|
254
|
+
* Improve metadata filtering so that it can match against any object
|
|
255
|
+
that implements `===` instead of treating regular expressions as
|
|
256
|
+
special. (Myron Marston, #2294)
|
|
257
|
+
* Improve `rspec -v` so that it prints out the versions of each part of
|
|
258
|
+
RSpec to prevent confusion. (Myron Marston, #2304)
|
|
259
|
+
* Add `config.fail_if_no_examples` option which causes RSpec to fail if
|
|
260
|
+
no examples are found. (Ewa Czechowska, #2302)
|
|
261
|
+
* Nicely format errors encountered while loading spec files.
|
|
262
|
+
(Myron Marston, #2323)
|
|
263
|
+
* Improve the API for enabling and disabling color output (Josh
|
|
264
|
+
Justice, #2321):
|
|
265
|
+
* Automatically enable color if the output is a TTY, since color is
|
|
266
|
+
nearly always desirable if the output can handle it.
|
|
267
|
+
* Introduce new CLI flag to force color on (`--force-color`), even
|
|
268
|
+
if the output is not a TTY. `--no-color` continues to work as well.
|
|
269
|
+
* Introduce `config.color_mode` for configuring the color from Ruby.
|
|
270
|
+
`:automatic` is the default and will produce color if the output is
|
|
271
|
+
a TTY. `:on` forces it on and `:off` forces it off.
|
|
272
|
+
|
|
273
|
+
### 3.5.4 / 2016-09-30
|
|
274
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.3...v3.5.4)
|
|
275
|
+
|
|
276
|
+
Bug Fixes:
|
|
277
|
+
|
|
278
|
+
* Remove accumulated `ExampleGroup` constants when reseting RSpec,
|
|
279
|
+
preventing a memory leak. (TravisSpangle, #2328)
|
|
280
|
+
|
|
281
|
+
### 3.5.3 / 2016-09-02
|
|
282
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.2...v3.5.3)
|
|
283
|
+
|
|
284
|
+
Bug Fixes:
|
|
285
|
+
|
|
286
|
+
* When applying shared group metadata to a host group, overwrite
|
|
287
|
+
conflicting keys if the value in the host group was inherited from
|
|
288
|
+
a parent group instead of being specified at that level.
|
|
289
|
+
(Myron Marston, #2307)
|
|
290
|
+
* Handle errors in `:suite` hooks and provide the same nicely formatted
|
|
291
|
+
output as errors that happen in examples. (Myron Marston, #2316)
|
|
292
|
+
* Set the exit status to non-zero when an error occurs in an
|
|
293
|
+
`after(:context)` hook. (Myron Marston, #2320)
|
|
294
|
+
|
|
295
|
+
### 3.5.2 / 2016-07-28
|
|
296
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.1...v3.5.2)
|
|
297
|
+
|
|
298
|
+
Bug Fixes:
|
|
299
|
+
|
|
300
|
+
* Wait to report `example_finished` until the example's `execution_result`
|
|
301
|
+
has been completely filled in. (Myron Marston, #2291)
|
|
302
|
+
* Make sure example block is still available when using `duplicate_with`
|
|
303
|
+
to clone examples. (bootstraponline, #2298)
|
|
304
|
+
* Don't include the default `--pattern` in the Rake task when
|
|
305
|
+
`rspec_opts` specifies its own. (Jon Rowe, #2305)
|
|
306
|
+
|
|
307
|
+
### 3.5.1 / 2016-07-06
|
|
308
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.0...v3.5.1)
|
|
309
|
+
|
|
310
|
+
Bug Fixes:
|
|
311
|
+
|
|
312
|
+
* Ensure that config hooks that are added to existing example groups are
|
|
313
|
+
added only once. (Eugene Kenny, #2280)
|
|
314
|
+
|
|
315
|
+
### 3.5.0 / 2016-07-01
|
|
316
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.0.beta4...v3.5.0)
|
|
317
|
+
|
|
318
|
+
Enhancements:
|
|
319
|
+
|
|
320
|
+
* Include any `SPEC_OPTS` in reproduction command printed at the end of
|
|
321
|
+
a bisect run. (Simon Coffey, #2274)
|
|
322
|
+
|
|
323
|
+
Bug Fixes:
|
|
324
|
+
|
|
325
|
+
* Handle `--bisect` in `SPEC_OPTS` environment variable correctly so as
|
|
326
|
+
to avoid infinite recursion. (Simon Coffey, #2271)
|
|
327
|
+
|
|
328
|
+
### 3.5.0.beta4 / 2016-06-05
|
|
329
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.0.beta3...v3.5.0.beta4)
|
|
330
|
+
|
|
331
|
+
Enhancements:
|
|
332
|
+
|
|
333
|
+
* Filter out bundler stackframes from backtraces by default, since
|
|
334
|
+
Bundler 1.12 now includes its own frames in stack traces produced
|
|
335
|
+
by using `bundle exec`. (Myron Marston, #2240)
|
|
336
|
+
* HTML Formatter uses exception presenter to get failure message
|
|
337
|
+
for consistency with other formatters. (@mrageh, #2222)
|
|
338
|
+
* Load spec files in the order of the directories or files passed
|
|
339
|
+
at the command line, making it easy to make some specs run before
|
|
340
|
+
others in a one-off manner. For example, `rspec spec/unit
|
|
341
|
+
spec/acceptance --order defined` will run unit specs before acceptance
|
|
342
|
+
specs. (Myron Marston, #2253)
|
|
343
|
+
* Add new `config.include_context` API for configuring global or
|
|
344
|
+
filtered inclusion of shared contexts in example groups.
|
|
345
|
+
(Myron Marston, #2256)
|
|
346
|
+
* Add new `config.shared_context_metadata_behavior = :apply_to_host_groups`
|
|
347
|
+
option, which causes shared context metadata to be inherited by the
|
|
348
|
+
metadata hash of all host groups and examples instead of configuring
|
|
349
|
+
implicit auto-inclusion based on the passed metadata. (Myron Marston, #2256)
|
|
350
|
+
|
|
351
|
+
Bug Fixes:
|
|
352
|
+
|
|
353
|
+
* Fix `--bisect` so it works on large spec suites that were previously triggering
|
|
354
|
+
"Argument list too long errors" due to all the spec locations being passed as
|
|
355
|
+
CLI args. (Matt Jones, #2223).
|
|
356
|
+
* Fix deprecated `:example_group`-based filtering so that it properly
|
|
357
|
+
applies to matching example groups. (Myron Marston, #2234)
|
|
358
|
+
* Fix `NoMethodError` caused by Java backtraces on JRuby. (Michele Piccirillo, #2244)
|
|
359
|
+
|
|
360
|
+
### 3.5.0.beta3 / 2016-04-02
|
|
361
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.0.beta2...v3.5.0.beta3)
|
|
362
|
+
|
|
363
|
+
Enhancements:
|
|
364
|
+
|
|
365
|
+
* Add new `config.filter_run_when_matching` API, intended to replace
|
|
366
|
+
the combination of `config.filter_run` and
|
|
367
|
+
`config.run_all_when_everything_filtered` (Myron Marston, #2206)
|
|
368
|
+
|
|
369
|
+
Bug Fixes:
|
|
370
|
+
|
|
371
|
+
* Use the encoded string logic for source extraction. (Jon Rowe, #2183)
|
|
372
|
+
* Fix rounding issue in duration formatting helper. (Fabersky, Jon Rowe, #2208)
|
|
373
|
+
* Fix failure snippet extraction so that `def-end` snippets
|
|
374
|
+
ending with `end`-only line can be extracted properly.
|
|
375
|
+
(Yuji Nakayama, #2215)
|
|
376
|
+
|
|
377
|
+
### 3.5.0.beta2 / 2016-03-10
|
|
378
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.5.0.beta1...v3.5.0.beta2)
|
|
379
|
+
|
|
380
|
+
Enhancements:
|
|
381
|
+
|
|
382
|
+
* Remove unneeded `:execution_result` example group metadata, saving a
|
|
383
|
+
bit of memory. (Myron Marston, #2172)
|
|
384
|
+
* Apply hooks registered with `config` to previously defined groups.
|
|
385
|
+
(Myron Marston, #2189)
|
|
386
|
+
* `RSpec::Core::Configuration#reporter` is now public API under SemVer.
|
|
387
|
+
(Jon Rowe, #2193)
|
|
388
|
+
* Add new `config.when_first_matching_example_defined` hook. (Myron
|
|
389
|
+
Marston, #2175)
|
|
390
|
+
|
|
391
|
+
### 3.5.0.beta1 / 2016-02-06
|
|
392
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.4.4...v3.5.0.beta1)
|
|
393
|
+
|
|
394
|
+
Enhancements:
|
|
395
|
+
|
|
396
|
+
* Add `RSpec::Core::ExampleGroup.currently_executing_a_context_hook?`,
|
|
397
|
+
primarily for use by rspec-rails. (Sam Phippen, #2131)
|
|
398
|
+
|
|
399
|
+
Bug Fixes:
|
|
400
|
+
|
|
401
|
+
* Ensure `MultipleExceptionError` does not contain a recursive reference
|
|
402
|
+
to itself. (Sam Phippen, #2133)
|
|
403
|
+
|
|
404
|
+
### 3.4.4 / 2016-03-09
|
|
405
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.4.3...v3.4.4)
|
|
406
|
+
|
|
407
|
+
Bug Fixes:
|
|
408
|
+
|
|
409
|
+
* Fix `RSpec::Core::RakeTask` so that it works with Rake 11.
|
|
410
|
+
(Travis Grathwell, #2197)
|
|
411
|
+
|
|
412
|
+
### 3.4.3 / 2016-02-19
|
|
413
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.4.2...v3.4.3)
|
|
414
|
+
|
|
415
|
+
Bug Fixes:
|
|
416
|
+
|
|
417
|
+
* Prevent a `TypeError` from occurring when running via the rake task when
|
|
418
|
+
Ruby crashes. (Patrik Wenger, #2161)
|
|
419
|
+
* Only consider example and group declaration lines from a specific file
|
|
420
|
+
when applying line number filtering, instead of considering all
|
|
421
|
+
declaration lines from all spec files. (Myron Marston, #2170)
|
|
422
|
+
* Fix failure snippet extraction so that snippets that contain `do-end` style
|
|
423
|
+
block and end with `end`-only line can be extracted properly.
|
|
424
|
+
(Yuji Nakayama, #2173)
|
|
425
|
+
* Prevent infinite recursion when an exception is caused by itself.
|
|
426
|
+
(Jon Rowe, #2128)
|
|
427
|
+
|
|
428
|
+
### 3.4.2 / 2016-01-26
|
|
429
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.4.1...v3.4.2)
|
|
430
|
+
|
|
431
|
+
Bug Fixes:
|
|
432
|
+
|
|
433
|
+
* Fix `rspec --profile` when an example calls `abort` or `exit`.
|
|
434
|
+
(Bradley Schaefer, #2144)
|
|
435
|
+
* Fix `--drb` so that when no DRb server is running, it prevents
|
|
436
|
+
the DRb connection error from being listed as the cause of all
|
|
437
|
+
expectation failures. (Myron Marston, #2156)
|
|
438
|
+
* Fix syntax highlighter so that it works when the `coderay` gem is
|
|
439
|
+
installed as a rubygem but not already available on your load path
|
|
440
|
+
(as happens when you use bundler). (Myron Marston, #2159)
|
|
441
|
+
|
|
442
|
+
### 3.4.1 / 2015-11-18
|
|
443
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.4.0...v3.4.1)
|
|
444
|
+
|
|
445
|
+
Bug Fixes:
|
|
446
|
+
|
|
447
|
+
* Fix backtrace formatter to handle backtraces that are `nil`.
|
|
448
|
+
(Myron Marston, #2118)
|
|
449
|
+
|
|
450
|
+
### 3.4.0 / 2015-11-11
|
|
451
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.3.2...v3.4.0)
|
|
452
|
+
|
|
453
|
+
Enhancements:
|
|
454
|
+
|
|
455
|
+
* Combine multiple `--pattern` arguments making them equivalent to
|
|
456
|
+
`--pattern=1,2,...,n`. (Jon Rowe, #2002)
|
|
457
|
+
* Improve `inspect` and `to_s` output for `RSpec::Core::Example`
|
|
458
|
+
objects, replacing Ruby's excessively verbose output. (Gavin Miller, #1922)
|
|
459
|
+
* Add `silence_filter_announcements` configuration option.
|
|
460
|
+
(David Raffensperger, #2007)
|
|
461
|
+
* Add optional `example_finished` notification to the reporter protocol for
|
|
462
|
+
when you don't care about the example outcome. (Jon Rowe, #2013)
|
|
463
|
+
* Switch `--bisect` to a recursion-based bisection algorithm rather than
|
|
464
|
+
a permutation-based one. This better handles cases where an example
|
|
465
|
+
depends upon multiple other examples instead of just one and minimizes
|
|
466
|
+
the number of runs necessary to determine that an example set cannot be
|
|
467
|
+
minimized further. (Simon Coffey, #1997)
|
|
468
|
+
* Allow simple filters (e.g. `:symbol` key only) to be triggered by truthey
|
|
469
|
+
values. (Tim Mertens, #2035)
|
|
470
|
+
* Remove unneeded warning about need for `ansicon` on Windows when using
|
|
471
|
+
RSpec's `--color` option. (Ashley Engelund, #2038)
|
|
472
|
+
* Add option to configure RSpec to raise errors when issuing warnings.
|
|
473
|
+
(Jon Rowe, #2052)
|
|
474
|
+
* Append the root `cause` of a failure or error to the printed failure
|
|
475
|
+
output when a `cause` is available. (Adam Magan)
|
|
476
|
+
* Stop rescuing `NoMemoryError`, `SignalExcepetion`, `Interrupt` and
|
|
477
|
+
`SystemExit`. It is dangerous to interfere with these. (Myron Marston, #2063)
|
|
478
|
+
* Add `config.project_source_dirs` setting which RSpec uses to determine
|
|
479
|
+
if a backtrace line comes from your project source or from some
|
|
480
|
+
external library. It defaults to `spec`, `lib` and `app` but can be
|
|
481
|
+
configured differently. (Myron Marston, #2088)
|
|
482
|
+
* Improve failure line detection so that it looks for the failure line
|
|
483
|
+
in any project source directory instead of just in the spec file.
|
|
484
|
+
In addition, if no backtrace lines can be found from a project source
|
|
485
|
+
file, we fall back to displaying the source of the first backtrace
|
|
486
|
+
line. This should virtually eliminate the "Unable to find matching
|
|
487
|
+
line from backtrace" messages. (Myron Marston, #2088)
|
|
488
|
+
* Add support for `:extra_failure_lines` example metadata that will
|
|
489
|
+
be appended to the failure output. (bootstraponline, #2092).
|
|
490
|
+
* Add `RSpec::Core::Example#duplicate_with` to produce new examples
|
|
491
|
+
with cloned metadata. (bootstraponline, #2098)
|
|
492
|
+
* Add `RSpec::Core::Configuration#on_example_group_definition` to register
|
|
493
|
+
hooks to be invoked when example groups are created. (bootstraponline, #2094)
|
|
494
|
+
* Add `add_example` and `remove_example` to `RSpec::Core::ExampleGroup` to
|
|
495
|
+
allow manipulating an example groups examples. (bootstraponline, #2095)
|
|
496
|
+
* Display multiline failure source lines in failure output when Ripper is
|
|
497
|
+
available (MRI >= 1.9.2, and JRuby >= 1.7.5 && < 9.0.0.0.rc1).
|
|
498
|
+
(Yuji Nakayama, #2083)
|
|
499
|
+
* Add `max_displayed_failure_line_count` configuration option
|
|
500
|
+
(defaults to 10). (Yuji Nakayama, #2083)
|
|
501
|
+
* Enhance `fail_fast` option so it can take a number (e.g. `--fail-fast=3`)
|
|
502
|
+
to force the run to abort after the specified number of failures.
|
|
503
|
+
(Jack Scotti, #2065)
|
|
504
|
+
* Syntax highlight the failure snippets in text formatters when `color`
|
|
505
|
+
is enabled and the `coderay` gem is installed on a POSIX system.
|
|
506
|
+
(Myron Marston, #2109)
|
|
507
|
+
|
|
508
|
+
Bug Fixes:
|
|
509
|
+
|
|
510
|
+
* Lock `example_status_persistence_file` when reading from and writing
|
|
511
|
+
to it to prevent race conditions when multiple processes try to use
|
|
512
|
+
it. (Ben Woosley, #2029)
|
|
513
|
+
* Fix regression in 3.3 that caused spec file names with square brackets in
|
|
514
|
+
them (such as `1[]_spec.rb`) to not be loaded properly. (Myron Marston, #2041)
|
|
515
|
+
* Fix output encoding issue caused by ASCII literal on 1.9.3 (Jon Rowe, #2072)
|
|
516
|
+
* Fix requires in `rspec/core/rake_task.rb` to avoid double requires
|
|
517
|
+
seen by some users. (Myron Marston, #2101)
|
|
518
|
+
|
|
519
|
+
### 3.3.2 / 2015-07-15
|
|
520
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.3.1...v3.3.2)
|
|
521
|
+
|
|
522
|
+
Bug Fixes:
|
|
523
|
+
|
|
524
|
+
* Fix formatters to handle exceptions for which `backtrace` returns `nil`.
|
|
525
|
+
(Myron Marston, #2023)
|
|
526
|
+
* Fix duplicate formatter detection so that it allows subclasses of formatters
|
|
527
|
+
to be added. (Sebastián Tello, #2019)
|
|
528
|
+
|
|
529
|
+
### 3.3.1 / 2015-06-18
|
|
530
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.3.0...v3.3.1)
|
|
531
|
+
|
|
532
|
+
Bug Fixes:
|
|
533
|
+
|
|
534
|
+
* Correctly run `before(:suite)` (and friends) in the context of an example
|
|
535
|
+
group instance, thus making the expected RSpec environment available.
|
|
536
|
+
(Jon Rowe, #1986)
|
|
537
|
+
|
|
538
|
+
### 3.3.0 / 2015-06-12
|
|
539
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.2.3...v3.3.0)
|
|
540
|
+
|
|
541
|
+
Enhancements:
|
|
542
|
+
|
|
543
|
+
* Expose the reporter used to run examples via `RSpec::Core::Example#reporter`.
|
|
544
|
+
(Jon Rowe, #1866)
|
|
545
|
+
* Make `RSpec::Core::Reporter#message` a public supported API. (Jon Rowe, #1866)
|
|
546
|
+
* Allow custom formatter events to be published via
|
|
547
|
+
`RSpec::Core::Reporter#publish(event_name, hash_of_attributes)`. (Jon Rowe, #1869)
|
|
548
|
+
* Remove dependency on the standard library `Set` and replace with `RSpec::Core::Set`.
|
|
549
|
+
(Jon Rowe, #1870)
|
|
550
|
+
* Assign a unique id to each example and group so that they can be
|
|
551
|
+
uniquely identified, even for shared examples (and similar situations)
|
|
552
|
+
where the location isn't unique. (Myron Marston, #1884)
|
|
553
|
+
* Use the example id in the rerun command printed for failed examples
|
|
554
|
+
when the location is not unique. (Myron Marston, #1884)
|
|
555
|
+
* Add `config.example_status_persistence_file_path` option, which is
|
|
556
|
+
used to persist the last run status of each example. (Myron Marston, #1888)
|
|
557
|
+
* Add `:last_run_status` metadata to each example, which indicates what
|
|
558
|
+
happened the last time an example ran. (Myron Marston, #1888)
|
|
559
|
+
* Add `--only-failures` CLI option which filters to only the examples
|
|
560
|
+
that failed the last time they ran. (Myron Marston, #1888)
|
|
561
|
+
* Add `--next-failure` CLI option which allows you to repeatedly focus
|
|
562
|
+
on just one of the currently failing examples, then move on to the
|
|
563
|
+
next failure, etc. (Myron Marston, #1888)
|
|
564
|
+
* Make `--order random` ordering stable, so that when you rerun a
|
|
565
|
+
subset with a given seed, the examples will be order consistently
|
|
566
|
+
relative to each other. (Myron Marston, #1908)
|
|
567
|
+
* Set example group constant earlier so errors when evaluating the context
|
|
568
|
+
include the example group name (Myron Marson, #1911)
|
|
569
|
+
* Make `let` and `subject` threadsafe. (Josh Cheek, #1858)
|
|
570
|
+
* Add version information into the JSON formatter. (Mark Swinson, #1883)
|
|
571
|
+
* Add `--bisect` CLI option, which will repeatedly run your suite in
|
|
572
|
+
order to isolate the failures to the smallest reproducible case.
|
|
573
|
+
(Myron Marston, #1917)
|
|
574
|
+
* For `config.include`, `config.extend` and `config.prepend`, apply the
|
|
575
|
+
module to previously defined matching example groups. (Eugene Kenny, #1935)
|
|
576
|
+
* When invalid options are parsed, notify users where they came from
|
|
577
|
+
(e.g. `.rspec` or `~/.rspec` or `ENV['SPEC_OPTS']`) so they can
|
|
578
|
+
easily find the source of the problem. (Myron Marston, #1940)
|
|
579
|
+
* Add pending message contents to the json formatter output. (Jon Rowe, #1949)
|
|
580
|
+
* Add shared group backtrace to the output displayed by the built-in
|
|
581
|
+
formatters for pending examples that have been fixed. (Myron Marston, #1946)
|
|
582
|
+
* Add support for `:aggregate_failures` metadata. Tag an example or
|
|
583
|
+
group with this metadata and it'll use rspec-expectations'
|
|
584
|
+
`aggregate_failures` feature to allow multiple failures in an example
|
|
585
|
+
and list them all, rather than aborting on the first failure. (Myron
|
|
586
|
+
Marston, #1946)
|
|
587
|
+
* When no formatter implements #message add a fallback to prevent those
|
|
588
|
+
messages being lost. (Jon Rowe, #1980)
|
|
589
|
+
* Profiling examples now takes into account time spent in `before(:context)`
|
|
590
|
+
hooks. (Denis Laliberté, Jon Rowe, #1971)
|
|
591
|
+
* Improve failure output when an example has multiple exceptions, such
|
|
592
|
+
as one from an `it` block and one from an `after` block. (Myron Marston, #1985)
|
|
593
|
+
|
|
594
|
+
Bug Fixes:
|
|
595
|
+
|
|
596
|
+
* Handle invalid UTF-8 strings within exception methods. (Benjamin Fleischer, #1760)
|
|
597
|
+
* Fix Rake Task quoting of file names with quotes to work properly on
|
|
598
|
+
Windows. (Myron Marston, #1887)
|
|
599
|
+
* Fix `RSpec::Core::RakeTask#failure_message` so that it gets printed
|
|
600
|
+
when the task failed. (Myron Marston, #1905)
|
|
601
|
+
* Make `let` work properly when defined in a shared context that is applied
|
|
602
|
+
to an individual example via metadata. (Myron Marston, #1912)
|
|
603
|
+
* Ensure `rspec/autorun` respects configuration defaults. (Jon Rowe, #1933)
|
|
604
|
+
* Prevent modules overriding example group defined methods when included,
|
|
605
|
+
prepended or extended by config defined after an example group. (Eugene Kenny, #1935)
|
|
606
|
+
* Fix regression which caused shared examples to be mistakenly run when specs
|
|
607
|
+
where filtered to a particular location. (Ben Axnick, #1963)
|
|
608
|
+
* Fix time formatting logic so that it displays 70 seconds as "1 minute,
|
|
609
|
+
10 seconds" rather than "1 minute, 1 second". (Paul Brennan, #1984)
|
|
610
|
+
* Fix regression where the formatter loader would allow duplicate formatters.
|
|
611
|
+
(Jon Rowe, #1990)
|
|
612
|
+
|
|
613
|
+
### 3.2.3 / 2015-04-06
|
|
614
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.2.2...v3.2.3)
|
|
615
|
+
|
|
616
|
+
Bug Fixes:
|
|
617
|
+
|
|
618
|
+
* Fix how the DSL methods are defined so that RSpec is compatible with
|
|
619
|
+
gems that define methods of the same name on `Kernel` (such as
|
|
620
|
+
the `its-it` gem). (Alex Kwiatkowski, Ryan Ong, #1907)
|
|
621
|
+
* Fix `before(:context) { skip }` so that it does not wrongly cause the
|
|
622
|
+
spec suite to exit with a non-zero status when no examples failed.
|
|
623
|
+
(Myron Marston, #1926)
|
|
624
|
+
|
|
625
|
+
### 3.2.2 / 2015-03-11
|
|
626
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.2.1...v3.2.2)
|
|
627
|
+
|
|
628
|
+
Bug Fixes:
|
|
629
|
+
|
|
630
|
+
* Fix regression in 3.2.0 that allowed tag-filtered examples to
|
|
631
|
+
run even if there was a location filter applied to the spec
|
|
632
|
+
file that was intended to limit the file to other examples.
|
|
633
|
+
(#1894, Myron Marston)
|
|
634
|
+
|
|
635
|
+
### 3.2.1 / 2015-02-23
|
|
636
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.2.0...v3.2.1)
|
|
637
|
+
|
|
638
|
+
Bug Fixes:
|
|
639
|
+
|
|
640
|
+
* Notify start-of-run seed _before_ `start` notification rather than
|
|
641
|
+
_after_ so that formatters like Fuubar work properly. (Samuel Esposito, #1882)
|
|
642
|
+
|
|
643
|
+
### 3.2.0 / 2015-02-03
|
|
644
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.7...v3.2.0)
|
|
645
|
+
|
|
646
|
+
Enhancements:
|
|
647
|
+
|
|
648
|
+
* Improve the `inspect` output of example groups. (Mike Dalton, #1687)
|
|
649
|
+
* When rake task fails, only output the command if `verbose` flag is
|
|
650
|
+
set. (Ben Snape, #1704)
|
|
651
|
+
* Add `RSpec.clear_examples` as a clear way to reset examples in between
|
|
652
|
+
spec runs, whilst retaining user configuration. (Alexey Fedorov, #1706)
|
|
653
|
+
* Reduce string allocations when defining and running examples by 70%
|
|
654
|
+
and 50% respectively. (Myron Marston, #1738)
|
|
655
|
+
* Removed dependency on pathname from stdlib. (Sam Phippen, #1703)
|
|
656
|
+
* Improve the message presented when a user hits Ctrl-C.
|
|
657
|
+
(Alex Chaffee #1717, #1742)
|
|
658
|
+
* Improve shared example group inclusion backtrace displayed
|
|
659
|
+
in failed example output so that it works for all methods
|
|
660
|
+
of including shared example groups and shows all inclusion
|
|
661
|
+
locations. (Myron Marston, #1763)
|
|
662
|
+
* Issue seed notification at start (as well as the end) of the reporter
|
|
663
|
+
run. (Arlandis Word, #1761)
|
|
664
|
+
* Improve the documentation of around hooks. (Jim Kingdon, #1772)
|
|
665
|
+
* Support prepending of modules into example groups from config and allow
|
|
666
|
+
filtering based on metadata. (Arlandis Word, #1806)
|
|
667
|
+
* Emit warnings when `:suite` hooks are registered on an example group
|
|
668
|
+
(where it has always been ignored) or are registered with metadata
|
|
669
|
+
(which has always been ignored). (Myron Marston, #1805)
|
|
670
|
+
* Provide a friendly error message when users call RSpec example group
|
|
671
|
+
APIs (e.g. `context`, `describe`, `it`, `let`, `before`, etc) from
|
|
672
|
+
within an example where those APIs are unavailable. (Myron Marston, #1819)
|
|
673
|
+
* Provide a friendly error message when users call RSpec example
|
|
674
|
+
APIs (e.g. `expect`, `double`, `stub_const`, etc) from
|
|
675
|
+
within an example group where those APIs are unavailable.
|
|
676
|
+
(Myron Marston, #1819)
|
|
677
|
+
* Add new `RSpec::Core::Sandbox.sandboxed { }` API that facilitates
|
|
678
|
+
testing RSpec with RSpec, allowing you to define example groups
|
|
679
|
+
and example from within an example without affecting the global
|
|
680
|
+
`RSpec.world` state. (Tyler Ball, 1808)
|
|
681
|
+
* Apply line-number filters only to the files they are scoped to,
|
|
682
|
+
allowing you to mix filtered and unfiltered files. (Myron Marston, #1839)
|
|
683
|
+
* When dumping pending examples, include the failure details so that you
|
|
684
|
+
don't have to un-pend the example to see it. (Myron Marston, #1844)
|
|
685
|
+
* Make `-I` option support multiple values when separated by
|
|
686
|
+
`File::PATH_SEPARATOR`, such as `rspec -I foo:bar`. This matches
|
|
687
|
+
the behavior of Ruby's `-I` option. (Fumiaki Matsushima, #1855).
|
|
688
|
+
* Treat each example as having a singleton example group for the
|
|
689
|
+
purposes of applying metadata-based features that normally apply
|
|
690
|
+
to example groups to individually tagged examples. For example,
|
|
691
|
+
`RSpec.shared_context "Uses redis", :uses_redis` will now apply
|
|
692
|
+
to individual examples tagged with `:uses_redis`, as will
|
|
693
|
+
`config.include RedisHelpers, :uses_redis`, and
|
|
694
|
+
`config.before(:context, :uses_redis) { }`, etc. (Myron Marston, #1749)
|
|
695
|
+
|
|
696
|
+
Bug Fixes:
|
|
697
|
+
|
|
698
|
+
* When assigning generated example descriptions, surface errors
|
|
699
|
+
raised by `matcher.description` in the example description.
|
|
700
|
+
(Myron Marston, #1771)
|
|
701
|
+
* Don't consider expectations from `after` hooks when generating
|
|
702
|
+
example descriptions. (Myron Marston, #1771)
|
|
703
|
+
* Don't apply metadata-filtered config hooks to examples in groups
|
|
704
|
+
with matching metadata when those examples override the parent
|
|
705
|
+
metadata value to not match. (Myron Marston, #1796)
|
|
706
|
+
* Fix `config.expect_with :minitest` so that `skip` uses RSpec's
|
|
707
|
+
implementation rather than Minitest's. (Jonathan Rochkind, #1822)
|
|
708
|
+
* Fix `NameError` caused when duplicate example group aliases are defined and
|
|
709
|
+
the DSL is not globally exposed. (Aaron Kromer, #1825)
|
|
710
|
+
* When a shared example defined in an external file fails, use the host
|
|
711
|
+
example group (from a loaded spec file) for the re-run command to
|
|
712
|
+
ensure the command will actually work. (Myron Marston, #1835)
|
|
713
|
+
* Fix location filtering to work properly for examples defined in
|
|
714
|
+
a nested example group within a shared example group defined in
|
|
715
|
+
an external file. (Bradley Schaefer, Xavier Shay, Myron Marston, #1837)
|
|
716
|
+
* When a pending example fails (as expected) due to a mock expectation,
|
|
717
|
+
set `RSpec::Core::Example::ExecutionResult#pending_exception` --
|
|
718
|
+
previously it was not being set but should have been. (Myron Marston, #1844)
|
|
719
|
+
* Fix rake task to work when `rspec-core` is installed in a directory
|
|
720
|
+
containing a space. (Guido Günther, #1845)
|
|
721
|
+
* Fix regression in 3.1 that caused `describe Regexp` to raise errors.
|
|
722
|
+
(Durran Jordan, #1853)
|
|
723
|
+
* Fix regression in 3.x that caused the profile information to be printed
|
|
724
|
+
after the summary. (Max Lincoln, #1857)
|
|
725
|
+
* Apply `--seed` before loading `--require` files so that required files
|
|
726
|
+
can access the provided seed. (Myron Marston, #1745)
|
|
727
|
+
* Handle `RSpec::Core::Formatters::DeprecationFormatter::FileStream` being
|
|
728
|
+
reopened with an IO stream, which sometimes happens with spring.
|
|
729
|
+
(Kevin Mook, #1757)
|
|
730
|
+
|
|
731
|
+
### 3.1.7 / 2014-10-11
|
|
732
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.6...v3.1.7)
|
|
733
|
+
|
|
734
|
+
Bug Fixes:
|
|
735
|
+
|
|
736
|
+
* Fix `Metadata.relative_path` so that for a current directory of
|
|
737
|
+
`/foo/bar`, `/foo/bar_1` is not wrongly converted to `._1`.
|
|
738
|
+
(Akos Vandra, #1730)
|
|
739
|
+
* Prevent constant lookup mistakenly finding `RSpec::ExampleGroups` generated
|
|
740
|
+
constants on 1.9.2 by appending a trailing `_` to the generated names.
|
|
741
|
+
(Jon Rowe, #1737)
|
|
742
|
+
* Fix bug in `:pending` metadata. If it got set in any way besides passing
|
|
743
|
+
it as part of the metadata literal passed to `it` (such as by using
|
|
744
|
+
`define_derived_metadata`), it did not have the desired effect,
|
|
745
|
+
instead marking the example as `:passed`. (Myron Marston, #1739)
|
|
746
|
+
|
|
747
|
+
### 3.1.6 / 2014-10-08
|
|
748
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.5...v3.1.6)
|
|
749
|
+
|
|
750
|
+
Bug Fixes:
|
|
751
|
+
|
|
752
|
+
* Fix regression in rake task pattern handling, that prevented patterns
|
|
753
|
+
that were relative from the current directory rather than from `spec`
|
|
754
|
+
from working properly. (Myron Marston, #1734)
|
|
755
|
+
* Prevent rake task from generating duplicate load path entries.
|
|
756
|
+
(Myron Marston, #1735)
|
|
757
|
+
|
|
758
|
+
### 3.1.5 / 2014-09-29
|
|
759
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.4...v3.1.5)
|
|
760
|
+
|
|
761
|
+
Bug Fixes:
|
|
762
|
+
|
|
763
|
+
* Fix issue with the rake task incorrectly escaping strings on Windows.
|
|
764
|
+
(Jon Rowe #1718)
|
|
765
|
+
* Support absolute path patterns. While this wasn't officially supported
|
|
766
|
+
previously, setting `rake_task.pattern` to an absolute path pattern in
|
|
767
|
+
RSpec 3.0 and before worked since it delegated to `FileList` internally
|
|
768
|
+
(but now just forwards the pattern on to the `rspec` command).
|
|
769
|
+
(Myron Marston, #1726)
|
|
770
|
+
|
|
771
|
+
### 3.1.4 / 2014-09-18
|
|
772
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.3...v3.1.4)
|
|
773
|
+
|
|
774
|
+
Bug Fixes:
|
|
775
|
+
|
|
776
|
+
* Fix implicit `subject` when using `describe false` or `describe nil`
|
|
777
|
+
so that it returns the provided primitive rather than the string
|
|
778
|
+
representation. (Myron Marston, #1710)
|
|
779
|
+
* Fix backtrace filtering to allow code in subdirectories of your
|
|
780
|
+
current working directory (such as vendor/bundle/...) to be filtered
|
|
781
|
+
from backtraces. (Myron Marston, #1708)
|
|
782
|
+
|
|
783
|
+
### 3.1.3 / 2014-09-15
|
|
784
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.2...v3.1.3)
|
|
785
|
+
|
|
786
|
+
Bug Fixes:
|
|
787
|
+
|
|
788
|
+
* Fix yet another regression in rake task pattern handling, to allow
|
|
789
|
+
`task.pattern = FileList["..."]` to work. That was never intended
|
|
790
|
+
to be supported but accidentally worked in 3.0 and earlier.
|
|
791
|
+
(Myron Marston, #1701)
|
|
792
|
+
* Fix pattern handling so that files are normalized to absolute paths
|
|
793
|
+
before subtracting the `--exclude-pattern` matched files from the
|
|
794
|
+
`--pattern` matched files so that it still works even if the patterns
|
|
795
|
+
are in slightly different forms (e.g. one starting with `./`).
|
|
796
|
+
(Christian Nelson, #1698)
|
|
797
|
+
|
|
798
|
+
### 3.1.2 / 2014-09-08
|
|
799
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.1...v3.1.2)
|
|
800
|
+
|
|
801
|
+
Bug Fixes:
|
|
802
|
+
|
|
803
|
+
* Fix another regression in rake task pattern handling, so that patterns
|
|
804
|
+
that start with `./` still work. (Christian Nelson, #1696)
|
|
805
|
+
|
|
806
|
+
### 3.1.1 / 2014-09-05
|
|
807
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.1.0...v3.1.1)
|
|
808
|
+
|
|
809
|
+
Bug Fixes:
|
|
810
|
+
|
|
811
|
+
* Fix a regression in rake task pattern handling, so that `rake_task.pattern = array`
|
|
812
|
+
works again. While we never intended to support array values (or even knew that worked!),
|
|
813
|
+
the implementation from 3.0 and earlier used `FileList` internally, which allows arrays.
|
|
814
|
+
The fix restores the old behavior. (Myron Marston, #1694)
|
|
815
|
+
|
|
816
|
+
### 3.1.0 / 2014-09-04
|
|
817
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.0.4...v3.1.0)
|
|
818
|
+
|
|
819
|
+
Enhancements:
|
|
820
|
+
|
|
821
|
+
* Update files generated by `rspec --init` so that warnings are enabled
|
|
822
|
+
in commented out section of `spec_helper` rather than `.rspec` so users
|
|
823
|
+
have to consciously opt-in to the setting. (Andrew Hooker, #1572)
|
|
824
|
+
* Update `spec_helper` generated by `rspec --init` so that it sets the new
|
|
825
|
+
rspec-expectations `include_chain_clauses_in_custom_matcher_descriptions`
|
|
826
|
+
config option (which will be on by default in RSpec 4) and also sets the
|
|
827
|
+
rspec-mocks `verify_partial_doubles` option (which will also default
|
|
828
|
+
to on in RSpec 4). (Myron Marston, #1647)
|
|
829
|
+
* Provide an `inspect` output for example procsy objects (used in around
|
|
830
|
+
hooks) that doesn't make them look like procs. (Jon Rowe, #1620)
|
|
831
|
+
* Remove a few unneeded `require` statements from
|
|
832
|
+
`rspec/core/rake_task.rb`, making it even more lighterweight.
|
|
833
|
+
(Myron Marston, #1640)
|
|
834
|
+
* Allow rspec-core to be used when neither rspec-mocks or
|
|
835
|
+
rspec-expectations are installed, without requiring any
|
|
836
|
+
user configuration. (Sam Phippen, Myron Marston, #1615)
|
|
837
|
+
* Don't filter out gems from backtraces by default. (The RSpec
|
|
838
|
+
gems will still be filtered). User feedback has indicated
|
|
839
|
+
that including gems in default backtraces will be useful.
|
|
840
|
+
(Myron Marston, #1641)
|
|
841
|
+
* Add new `config.filter_gems_from_backtrace "rack", "rake"` API
|
|
842
|
+
to easily filter the named gems from backtraces. (Myron Marston, #1682)
|
|
843
|
+
* Fix default backtrace filters so that the RSpec binary is
|
|
844
|
+
excluded when installing RSpec as a bundler `:git` dependency.
|
|
845
|
+
(Myron Marston, #1648)
|
|
846
|
+
* Simplify command generated by the rake task so that it no longer
|
|
847
|
+
includes unnecessary `-S`. (Myron Marston, #1559)
|
|
848
|
+
* Add `--exclude-pattern` CLI option, `config.exclude_pattern =` config
|
|
849
|
+
option and `task.exclude_pattern =` rake task config option. Matching
|
|
850
|
+
files will be excluded. (John Gesimondo, Myron Marston, #1651, #1671)
|
|
851
|
+
* When an around hook fails to execute the example, mark it as
|
|
852
|
+
pending (rather than passing) so the user is made aware of the
|
|
853
|
+
fact that the example did not actually run. (Myron Marston, #1660)
|
|
854
|
+
* Remove dependency on `FileUtils` from the standard library so that users do
|
|
855
|
+
not get false positives where their code relies on it but they are not
|
|
856
|
+
requiring it. (Sam Phippen, #1565)
|
|
857
|
+
|
|
858
|
+
Bug Fixes:
|
|
859
|
+
|
|
860
|
+
* Fix rake task `t.pattern =` option so that it does not run all specs
|
|
861
|
+
when it matches no files, by passing along a `--pattern` option to
|
|
862
|
+
the `rspec` command, rather than resolving the file list and passing
|
|
863
|
+
along the files individually. (Evgeny Zislis, #1653)
|
|
864
|
+
* Fix rake task default pattern so that it follows symlinks properly.
|
|
865
|
+
(Myron Marston, #1672)
|
|
866
|
+
* Fix default pattern used with `rspec` command so that it follows
|
|
867
|
+
symlinks properly. (Myron Marston, #1672)
|
|
868
|
+
* Change how we assign constant names to example group classes so that
|
|
869
|
+
it avoids a problem with `describe "Core"`. (Daniela Wellisz, #1679)
|
|
870
|
+
* Handle rendering exceptions that have a different encoding than that
|
|
871
|
+
of their original source file. (Jon Rowe, #1681)
|
|
872
|
+
* Allow access to message_lines without colour for failed examples even
|
|
873
|
+
when they're part of a shared example group. (tomykaira, #1689)
|
|
874
|
+
|
|
1
875
|
### 3.0.4 / 2014-08-14
|
|
2
876
|
[Full Changelog](http://github.com/rspec/rspec-core/compare/v3.0.3...v3.0.4)
|
|
3
877
|
|
|
@@ -312,6 +1186,9 @@ Bug Fixes:
|
|
|
312
1186
|
directory (was broken in beta1). (Jon Rowe)
|
|
313
1187
|
* Prevent RSpec mangling file names that have substrings containing `line_number`
|
|
314
1188
|
or `default_path`. (Matijs van Zuijlen)
|
|
1189
|
+
* Fix failure line detection so that it handles relative file paths
|
|
1190
|
+
(which can happen when running specs through `ruby` using `rspec/autorun`).
|
|
1191
|
+
(Myron Marston, #1829)
|
|
315
1192
|
|
|
316
1193
|
### 3.0.0.beta1 / 2013-11-07
|
|
317
1194
|
[Full Changelog](http://github.com/rspec/rspec-core/compare/v2.99.1...v3.0.0.beta1)
|
|
@@ -385,6 +1262,14 @@ Deprecations:
|
|
|
385
1262
|
longer has an affect now that the behavior it enabled is always
|
|
386
1263
|
enabled. (Myron Marston)
|
|
387
1264
|
|
|
1265
|
+
### 2.99.2 / 2014-08-19
|
|
1266
|
+
[Full Changelog](http://github.com/rspec/rspec-core/compare/v2.99.1...v2.99.2)
|
|
1267
|
+
|
|
1268
|
+
Enhancements:
|
|
1269
|
+
|
|
1270
|
+
* Improve deprecation warning for RSpec 3 change in `describe <a symbol>`
|
|
1271
|
+
behavior. (Jon Rowe, #1667)
|
|
1272
|
+
|
|
388
1273
|
### 2.99.1 / 2014-06-19
|
|
389
1274
|
[Full Changelog](http://github.com/rspec/rspec-core/compare/v2.99.0...v2.99.1)
|
|
390
1275
|
|
|
@@ -1250,7 +2135,7 @@ project's root directory or in your home directory:
|
|
|
1250
2135
|
|
|
1251
2136
|
require "autotest/bundler"
|
|
1252
2137
|
|
|
1253
|
-
Now you can just type 'autotest' on the
|
|
2138
|
+
Now you can just type 'autotest' on the command line and it will work as you expect.
|
|
1254
2139
|
|
|
1255
2140
|
If you don't want 'bundle exec', there is nothing you have to do.
|
|
1256
2141
|
|
|
@@ -1343,6 +2228,7 @@ Bug fixes
|
|
|
1343
2228
|
[Full Changelog](http://github.com/rspec/rspec-core/compare/v2.2.0...v2.2.1)
|
|
1344
2229
|
|
|
1345
2230
|
Bug fixes
|
|
2231
|
+
|
|
1346
2232
|
* alias_method instead of override Kernel#method_missing (John Wilger)
|
|
1347
2233
|
* changed --autotest to --tty in generated command (MIKAMI Yoshiyuki)
|
|
1348
2234
|
* revert change to debugger (had introduced conflict with Rails)
|
|
@@ -1438,7 +2324,7 @@ Bug fixes
|
|
|
1438
2324
|
Enhancements
|
|
1439
2325
|
|
|
1440
2326
|
* implicitly require unknown formatters so you don't have to require the file
|
|
1441
|
-
explicitly on the
|
|
2327
|
+
explicitly on the command line (Michael Grosser)
|
|
1442
2328
|
* add --out/-o option to assign output target
|
|
1443
2329
|
* added fail_fast configuration option to abort on first failure
|
|
1444
2330
|
* support a Hash subject (its([:key]) { should == value }) (Josep M. Bach)
|