rspec-rails 6.1.3 → 6.1.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/Changelog.md +18 -1
- data/lib/generators/rspec/install/templates/spec/rails_helper.rb +1 -1
- data/lib/generators/rspec/scaffold/templates/index_spec.rb +1 -1
- data/lib/rspec/rails/matchers/active_job.rb +6 -6
- data/lib/rspec/rails/matchers/have_http_status.rb +1 -1
- data/lib/rspec/rails/tasks/rspec.rake +3 -1
- data/lib/rspec/rails/version.rb +1 -1
- data/lib/rspec-rails.rb +1 -0
- data.tar.gz.sig +0 -0
- metadata +5 -5
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 794b82d1aea01113c12d4d6d6baab45e129466eb3da90a6f237f97a600489c44
|
4
|
+
data.tar.gz: 492866fad93a1945fdb95b6ed10b0ec1739575d8769f83845f7572b450042b2f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: da28fe40ba3272d1a91e9c4be4d92a3aa88fc041ce69f904bc4e121b82e21affc6946a29df87be201bdda938a44f2057b3ac8c79dcfa20ada543bd604cbbeea7
|
7
|
+
data.tar.gz: 69ac337cdc6b192929d1812e69ab148154484500bf655a47bd8575d664ace8101b2ec9b8d054133f1117371099402f4e07f4bc02066666a57148a0f658a67ad6
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/Changelog.md
CHANGED
@@ -1,5 +1,22 @@
|
|
1
1
|
### Development
|
2
|
-
[Full Changelog](https://github.com/rspec/rspec-rails/compare/v6.1.
|
2
|
+
[Full Changelog](https://github.com/rspec/rspec-rails/compare/v6.1.5...6-1-maintenance)
|
3
|
+
|
4
|
+
### 6.1.5 / 2024-09-02
|
5
|
+
[Full Changelog](https://github.com/rspec/rspec-rails/compare/v6.1.4...v6.1.5)
|
6
|
+
|
7
|
+
Bug Fixes:
|
8
|
+
|
9
|
+
* Restore old order of requiring support files. (Franz Liedke, #2785)
|
10
|
+
* Prevent running `rake spec:statsetup` on Rails main / 8.0.0. (Petrik de Heus, #2781)
|
11
|
+
|
12
|
+
### 6.1.4 / 2024-08-15
|
13
|
+
[Full Changelog](https://github.com/rspec/rspec-rails/compare/v6.1.3...v6.1.4)
|
14
|
+
|
15
|
+
Bug Fixes:
|
16
|
+
|
17
|
+
* Prevent `have_http_status` matcher raising an error when encountering a raw `Rack::MockResponse`.
|
18
|
+
(Christophe Bliard, #2771)
|
19
|
+
* Move Rails version conditional from index scaffold generated file to template. (Matt Jankowski, #2777)
|
3
20
|
|
4
21
|
### 6.1.3 / 2024-06-19
|
5
22
|
[Full Changelog](https://github.com/rspec/rspec-rails/compare/v6.1.2...v6.1.3)
|
@@ -20,7 +20,7 @@ require 'rspec/rails'
|
|
20
20
|
# directory. Alternatively, in the individual `*_spec.rb` files, manually
|
21
21
|
# require only the support files necessary.
|
22
22
|
#
|
23
|
-
# Rails.root.glob('spec/support/**/*.rb').
|
23
|
+
# Rails.root.glob('spec/support/**/*.rb').sort_by(&:to_s).each { |f| require f }
|
24
24
|
|
25
25
|
<% if RSpec::Rails::FeatureCheck.has_active_record_migration? -%>
|
26
26
|
# Checks for pending migrations and applies them before tests are run.
|
@@ -18,7 +18,7 @@ RSpec.describe "<%= ns_table_name %>/index", <%= type_metatag(:view) %> do
|
|
18
18
|
|
19
19
|
it "renders a list of <%= ns_table_name %>" do
|
20
20
|
render
|
21
|
-
cell_selector = Rails::VERSION::STRING >= '7' ? 'div>p' : 'tr>td'
|
21
|
+
cell_selector = <%= Rails::VERSION::STRING >= '7' ? "'div>p'" : "'tr>td'" %>
|
22
22
|
<% for attribute in output_attributes -%>
|
23
23
|
assert_select cell_selector, text: Regexp.new(<%= value_for(attribute) %>.to_s), count: 2
|
24
24
|
<% end -%>
|
@@ -384,33 +384,33 @@ module RSpec
|
|
384
384
|
#
|
385
385
|
# @example
|
386
386
|
# expect {
|
387
|
-
#
|
387
|
+
# perform_enqueued_jobs { HeavyLiftingJob.perform_later }
|
388
388
|
# }.to have_performed_job
|
389
389
|
#
|
390
390
|
# expect {
|
391
|
-
#
|
391
|
+
# perform_enqueued_jobs {
|
392
392
|
# HelloJob.perform_later
|
393
393
|
# HeavyLiftingJob.perform_later
|
394
394
|
# }
|
395
395
|
# }.to have_performed_job(HelloJob).exactly(:once)
|
396
396
|
#
|
397
397
|
# expect {
|
398
|
-
#
|
398
|
+
# perform_enqueued_jobs { 3.times { HelloJob.perform_later } }
|
399
399
|
# }.to have_performed_job(HelloJob).at_least(2).times
|
400
400
|
#
|
401
401
|
# expect {
|
402
|
-
#
|
402
|
+
# perform_enqueued_jobs { HelloJob.perform_later }
|
403
403
|
# }.to have_performed_job(HelloJob).at_most(:twice)
|
404
404
|
#
|
405
405
|
# expect {
|
406
|
-
#
|
406
|
+
# perform_enqueued_jobs {
|
407
407
|
# HelloJob.perform_later
|
408
408
|
# HeavyLiftingJob.perform_later
|
409
409
|
# }
|
410
410
|
# }.to have_performed_job(HelloJob).and have_performed_job(HeavyLiftingJob)
|
411
411
|
#
|
412
412
|
# expect {
|
413
|
-
#
|
413
|
+
# perform_enqueued_jobs {
|
414
414
|
# HelloJob.set(wait_until: Date.tomorrow.noon, queue: "low").perform_later(42)
|
415
415
|
# }
|
416
416
|
# }.to have_performed_job.with(42).on_queue("low").at(Date.tomorrow.noon)
|
@@ -33,7 +33,7 @@ module RSpec
|
|
33
33
|
# @param obj [Object] object to convert to a response
|
34
34
|
# @return [ActionDispatch::TestResponse]
|
35
35
|
def as_test_response(obj)
|
36
|
-
if ::ActionDispatch::Response === obj
|
36
|
+
if ::ActionDispatch::Response === obj || ::Rack::MockResponse === obj
|
37
37
|
::ActionDispatch::TestResponse.from_response(obj)
|
38
38
|
elsif ::ActionDispatch::TestResponse === obj
|
39
39
|
obj
|
data/lib/rspec/rails/version.rb
CHANGED
data/lib/rspec-rails.rb
CHANGED
@@ -9,6 +9,7 @@ module RSpec
|
|
9
9
|
# As of Rails 5.1.0 you can register directories to work with `rake notes`
|
10
10
|
require 'rails/source_annotation_extractor'
|
11
11
|
::Rails::SourceAnnotationExtractor::Annotation.register_directories("spec")
|
12
|
+
|
12
13
|
generators = config.app_generators
|
13
14
|
generators.integration_tool :rspec
|
14
15
|
generators.test_framework :rspec
|
data.tar.gz.sig
CHANGED
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rspec-rails
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.1.
|
4
|
+
version: 6.1.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- David Chelimsky
|
@@ -44,7 +44,7 @@ cert_chain:
|
|
44
44
|
ZsVDj6a7lH3cNqtWXZxrb2wO38qV5AkYj8SQK7Hj3/Yui9myUX3crr+PdetazSqQ
|
45
45
|
F3MdtaDehhjC
|
46
46
|
-----END CERTIFICATE-----
|
47
|
-
date: 2024-
|
47
|
+
date: 2024-09-02 00:00:00.000000000 Z
|
48
48
|
dependencies:
|
49
49
|
- !ruby/object:Gem::Dependency
|
50
50
|
name: actionpack
|
@@ -186,7 +186,7 @@ dependencies:
|
|
186
186
|
- - "~>"
|
187
187
|
- !ruby/object:Gem::Version
|
188
188
|
version: '7.0'
|
189
|
-
description: rspec-rails
|
189
|
+
description: rspec-rails integrates the Rails testing helpers into RSpec.
|
190
190
|
email: rspec@googlegroups.com
|
191
191
|
executables: []
|
192
192
|
extensions: []
|
@@ -297,7 +297,7 @@ licenses:
|
|
297
297
|
- MIT
|
298
298
|
metadata:
|
299
299
|
bug_tracker_uri: https://github.com/rspec/rspec-rails/issues
|
300
|
-
changelog_uri: https://github.com/rspec/rspec-rails/blob/v6.1.
|
300
|
+
changelog_uri: https://github.com/rspec/rspec-rails/blob/v6.1.5/Changelog.md
|
301
301
|
documentation_uri: https://rspec.info/documentation/
|
302
302
|
mailing_list_uri: https://groups.google.com/forum/#!forum/rspec
|
303
303
|
source_code_uri: https://github.com/rspec/rspec-rails
|
@@ -317,7 +317,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
317
317
|
- !ruby/object:Gem::Version
|
318
318
|
version: '0'
|
319
319
|
requirements: []
|
320
|
-
rubygems_version: 3.
|
320
|
+
rubygems_version: 3.5.11
|
321
321
|
signing_key:
|
322
322
|
specification_version: 4
|
323
323
|
summary: RSpec for Rails
|
metadata.gz.sig
CHANGED
Binary file
|