This repository was archived by the owner on Nov 30, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Expand file tree Collapse file tree 2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -322,6 +322,8 @@ def full_description
322
322
# @private
323
323
RESERVED_KEYS = [
324
324
:description ,
325
+ :description_args ,
326
+ :described_class ,
325
327
:example_group ,
326
328
:parent_example_group ,
327
329
:execution_result ,
@@ -332,7 +334,8 @@ def full_description
332
334
:line_number ,
333
335
:location ,
334
336
:scoped_id ,
335
- :block
337
+ :block ,
338
+ :shared_group_inclusion_backtrace
336
339
]
337
340
end
338
341
Original file line number Diff line number Diff line change @@ -31,6 +31,15 @@ module Core
31
31
32
32
end
33
33
34
+ specify 'RESERVED_KEYS contains all keys assigned by RSpec (and vice versa)' do
35
+ group = RSpec . describe ( "group" )
36
+ example = group . example ( "example" ) { }
37
+ nested_group = group . describe ( "nested" )
38
+
39
+ assigned_keys = group . metadata . keys | example . metadata . keys | nested_group . metadata . keys
40
+ expect ( RSpec ::Core ::Metadata ::RESERVED_KEYS ) . to match_array ( assigned_keys )
41
+ end
42
+
34
43
context "when created" do
35
44
Metadata ::RESERVED_KEYS . each do |key |
36
45
it "prohibits :#{ key } as a hash key for an example group" do
You can’t perform that action at this time.
0 commit comments