rspec-viewcomponent 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA256:
3
+ metadata.gz: 66f88185e9dbbb04d693bf3026e62894da4737d5b5f69bfa9b28b850eedf7054
4
+ data.tar.gz: 715c763bfbe88b6472ba8882e46e3e1afb914e5b849a53b92d939464037f404c
5
+ SHA512:
6
+ metadata.gz: d7ecc039189cc883df617ee1319cc032e4ebb763495df9275acbc918042e5e59e2ceb395e0c1c2eda1c88a4bdd6fe59d7076f72f803f8a4b165b4e3557c7e719
7
+ data.tar.gz: d6e94f17b79b6f57a7ce4d88cef6136bf809242427b07c3f124420a535f3196b5c7a75e360c90a3795bac4d8da3188f1f519517e3fc119dc5e8d73d1aae6f9c8
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --format documentation
2
+ --color
3
+ --require spec_helper
data/.standard.yml ADDED
@@ -0,0 +1,2 @@
1
+ # For available configuration options, see:
2
+ # https://github.com/testdouble/standard
data/.tool-versions ADDED
@@ -0,0 +1 @@
1
+ ruby 3.1.1
data/Appraisals ADDED
@@ -0,0 +1,30 @@
1
+ # frozen_string_literal: true
2
+
3
+ if RUBY_VERSION < "3.0.0"
4
+ appraise "rails-5.2" do
5
+ gem "rails", "~> 5.2.0"
6
+ end
7
+ else
8
+ puts "WARNING: Skipping Rails 5.2, as it is not compatible with Ruby >= 3.0.0"
9
+ end
10
+
11
+ appraise "rails-6.0" do
12
+ gem "rails", "~> 6.0.0"
13
+ end
14
+
15
+ appraise "rails-6.1" do
16
+ gem "rails", "~> 6.1.0"
17
+
18
+ # Required for Ruby 3.1.0
19
+ gem "net-smtp", require: false
20
+ gem "net-imap", require: false
21
+ gem "net-pop", require: false
22
+ end
23
+
24
+ appraise "rails-7.0" do
25
+ gem "rails", "~> 7.0.0"
26
+ end
27
+
28
+ appraise "rails-head" do
29
+ gem "rails", github: "rails/rails", branch: "main"
30
+ end
data/CHANGELOG.md ADDED
@@ -0,0 +1,5 @@
1
+ ## [Unreleased]
2
+
3
+ ## [0.1.0] - 2022-08-12
4
+
5
+ - Initial release
@@ -0,0 +1,84 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ We as members, contributors, and leaders pledge to make participation in our community a harassment-free experience for everyone, regardless of age, body size, visible or invisible disability, ethnicity, sex characteristics, gender identity and expression, level of experience, education, socio-economic status, nationality, personal appearance, race, religion, or sexual identity and orientation.
6
+
7
+ We pledge to act and interact in ways that contribute to an open, welcoming, diverse, inclusive, and healthy community.
8
+
9
+ ## Our Standards
10
+
11
+ Examples of behavior that contributes to a positive environment for our community include:
12
+
13
+ * Demonstrating empathy and kindness toward other people
14
+ * Being respectful of differing opinions, viewpoints, and experiences
15
+ * Giving and gracefully accepting constructive feedback
16
+ * Accepting responsibility and apologizing to those affected by our mistakes, and learning from the experience
17
+ * Focusing on what is best not just for us as individuals, but for the overall community
18
+
19
+ Examples of unacceptable behavior include:
20
+
21
+ * The use of sexualized language or imagery, and sexual attention or
22
+ advances of any kind
23
+ * Trolling, insulting or derogatory comments, and personal or political attacks
24
+ * Public or private harassment
25
+ * Publishing others' private information, such as a physical or email
26
+ address, without their explicit permission
27
+ * Other conduct which could reasonably be considered inappropriate in a
28
+ professional setting
29
+
30
+ ## Enforcement Responsibilities
31
+
32
+ Community leaders are responsible for clarifying and enforcing our standards of acceptable behavior and will take appropriate and fair corrective action in response to any behavior that they deem inappropriate, threatening, offensive, or harmful.
33
+
34
+ Community leaders have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, and will communicate reasons for moderation decisions when appropriate.
35
+
36
+ ## Scope
37
+
38
+ This Code of Conduct applies within all community spaces, and also applies when an individual is officially representing the community in public spaces. Examples of representing our community include using an official e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event.
39
+
40
+ ## Enforcement
41
+
42
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be reported to the community leaders responsible for enforcement at si@mon.fish. All complaints will be reviewed and investigated promptly and fairly.
43
+
44
+ All community leaders are obligated to respect the privacy and security of the reporter of any incident.
45
+
46
+ ## Enforcement Guidelines
47
+
48
+ Community leaders will follow these Community Impact Guidelines in determining the consequences for any action they deem in violation of this Code of Conduct:
49
+
50
+ ### 1. Correction
51
+
52
+ **Community Impact**: Use of inappropriate language or other behavior deemed unprofessional or unwelcome in the community.
53
+
54
+ **Consequence**: A private, written warning from community leaders, providing clarity around the nature of the violation and an explanation of why the behavior was inappropriate. A public apology may be requested.
55
+
56
+ ### 2. Warning
57
+
58
+ **Community Impact**: A violation through a single incident or series of actions.
59
+
60
+ **Consequence**: A warning with consequences for continued behavior. No interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, for a specified period of time. This includes avoiding interactions in community spaces as well as external channels like social media. Violating these terms may lead to a temporary or permanent ban.
61
+
62
+ ### 3. Temporary Ban
63
+
64
+ **Community Impact**: A serious violation of community standards, including sustained inappropriate behavior.
65
+
66
+ **Consequence**: A temporary ban from any sort of interaction or public communication with the community for a specified period of time. No public or private interaction with the people involved, including unsolicited interaction with those enforcing the Code of Conduct, is allowed during this period. Violating these terms may lead to a permanent ban.
67
+
68
+ ### 4. Permanent Ban
69
+
70
+ **Community Impact**: Demonstrating a pattern of violation of community standards, including sustained inappropriate behavior, harassment of an individual, or aggression toward or disparagement of classes of individuals.
71
+
72
+ **Consequence**: A permanent ban from any sort of public interaction within the community.
73
+
74
+ ## Attribution
75
+
76
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 2.0,
77
+ available at https://www.contributor-covenant.org/version/2/0/code_of_conduct.html.
78
+
79
+ Community Impact Guidelines were inspired by [Mozilla's code of conduct enforcement ladder](https://github.com/mozilla/diversity).
80
+
81
+ [homepage]: https://www.contributor-covenant.org
82
+
83
+ For answers to common questions about this code of conduct, see the FAQ at
84
+ https://www.contributor-covenant.org/faq. Translations are available at https://www.contributor-covenant.org/translations.
data/Gemfile ADDED
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ source "https://rubygems.org"
4
+
5
+ # Specify your gem's dependencies in rspec-viewcomponent.gemspec
6
+ gemspec
7
+
8
+ gem "view_component", github: "github/view_component", branch: "fix-config-loading-where-vc-is-a-dependency"
data/Gemfile.lock ADDED
@@ -0,0 +1,160 @@
1
+ GIT
2
+ remote: https://github.com/github/view_component.git
3
+ revision: 767e0d18d0ebdcc1ca25f920eb25c0e9cb7a88ec
4
+ branch: fix-config-loading-where-vc-is-a-dependency
5
+ specs:
6
+ view_component (2.66.0)
7
+ activesupport (>= 5.0.0, < 8.0)
8
+ concurrent-ruby (~> 1.0)
9
+ method_source (~> 1.0)
10
+
11
+ PATH
12
+ remote: .
13
+ specs:
14
+ rspec-viewcomponent (0.1.0)
15
+ activesupport (>= 5.0.0, < 8.0)
16
+
17
+ GEM
18
+ remote: https://rubygems.org/
19
+ specs:
20
+ actionpack (7.0.2.3)
21
+ actionview (= 7.0.2.3)
22
+ activesupport (= 7.0.2.3)
23
+ rack (~> 2.0, >= 2.2.0)
24
+ rack-test (>= 0.6.3)
25
+ rails-dom-testing (~> 2.0)
26
+ rails-html-sanitizer (~> 1.0, >= 1.2.0)
27
+ actionview (7.0.2.3)
28
+ activesupport (= 7.0.2.3)
29
+ builder (~> 3.1)
30
+ erubi (~> 1.4)
31
+ rails-dom-testing (~> 2.0)
32
+ rails-html-sanitizer (~> 1.1, >= 1.2.0)
33
+ activesupport (7.0.2.3)
34
+ concurrent-ruby (~> 1.0, >= 1.0.2)
35
+ i18n (>= 1.6, < 2)
36
+ minitest (>= 5.1)
37
+ tzinfo (~> 2.0)
38
+ addressable (2.8.0)
39
+ public_suffix (>= 2.0.2, < 5.0)
40
+ appraisal (2.4.1)
41
+ bundler
42
+ rake
43
+ thor (>= 0.14.0)
44
+ ast (2.4.2)
45
+ builder (3.2.4)
46
+ byebug (11.1.3)
47
+ capybara (3.36.0)
48
+ addressable
49
+ matrix
50
+ mini_mime (>= 0.1.3)
51
+ nokogiri (~> 1.8)
52
+ rack (>= 1.6.0)
53
+ rack-test (>= 0.6.3)
54
+ regexp_parser (>= 1.5, < 3.0)
55
+ xpath (~> 3.2)
56
+ combustion (1.3.7)
57
+ activesupport (>= 3.0.0)
58
+ railties (>= 3.0.0)
59
+ thor (>= 0.14.6)
60
+ concurrent-ruby (1.1.10)
61
+ crass (1.0.6)
62
+ diff-lcs (1.5.0)
63
+ erubi (1.11.0)
64
+ i18n (1.10.0)
65
+ concurrent-ruby (~> 1.0)
66
+ loofah (2.18.0)
67
+ crass (~> 1.0.2)
68
+ nokogiri (>= 1.5.9)
69
+ matrix (0.4.2)
70
+ method_source (1.0.0)
71
+ mini_mime (1.1.2)
72
+ minitest (5.15.0)
73
+ nokogiri (1.13.8-arm64-darwin)
74
+ racc (~> 1.4)
75
+ nokogiri (1.13.8-x86_64-linux)
76
+ racc (~> 1.4)
77
+ parallel (1.21.0)
78
+ parser (3.1.0.0)
79
+ ast (~> 2.4.1)
80
+ public_suffix (4.0.6)
81
+ racc (1.6.0)
82
+ rack (2.2.4)
83
+ rack-test (2.0.2)
84
+ rack (>= 1.3)
85
+ rails-dom-testing (2.0.3)
86
+ activesupport (>= 4.2.0)
87
+ nokogiri (>= 1.6)
88
+ rails-html-sanitizer (1.4.3)
89
+ loofah (~> 2.3)
90
+ railties (7.0.2.3)
91
+ actionpack (= 7.0.2.3)
92
+ activesupport (= 7.0.2.3)
93
+ method_source
94
+ rake (>= 12.2)
95
+ thor (~> 1.0)
96
+ zeitwerk (~> 2.5)
97
+ rainbow (3.1.1)
98
+ rake (13.0.6)
99
+ regexp_parser (2.2.1)
100
+ rexml (3.2.5)
101
+ rspec-core (3.11.0)
102
+ rspec-support (~> 3.11.0)
103
+ rspec-expectations (3.11.0)
104
+ diff-lcs (>= 1.2.0, < 2.0)
105
+ rspec-support (~> 3.11.0)
106
+ rspec-mocks (3.11.0)
107
+ diff-lcs (>= 1.2.0, < 2.0)
108
+ rspec-support (~> 3.11.0)
109
+ rspec-rails (5.0.2)
110
+ actionpack (>= 5.2)
111
+ activesupport (>= 5.2)
112
+ railties (>= 5.2)
113
+ rspec-core (~> 3.10)
114
+ rspec-expectations (~> 3.10)
115
+ rspec-mocks (~> 3.10)
116
+ rspec-support (~> 3.10)
117
+ rspec-support (3.11.0)
118
+ rubocop (1.24.1)
119
+ parallel (~> 1.10)
120
+ parser (>= 3.0.0.0)
121
+ rainbow (>= 2.2.2, < 4.0)
122
+ regexp_parser (>= 1.8, < 3.0)
123
+ rexml
124
+ rubocop-ast (>= 1.15.1, < 2.0)
125
+ ruby-progressbar (~> 1.7)
126
+ unicode-display_width (>= 1.4.0, < 3.0)
127
+ rubocop-ast (1.15.2)
128
+ parser (>= 3.0.1.1)
129
+ rubocop-performance (1.13.1)
130
+ rubocop (>= 1.7.0, < 2.0)
131
+ rubocop-ast (>= 0.4.0)
132
+ ruby-progressbar (1.11.0)
133
+ standard (1.6.0)
134
+ rubocop (= 1.24.1)
135
+ rubocop-performance (= 1.13.1)
136
+ thor (1.2.1)
137
+ tzinfo (2.0.4)
138
+ concurrent-ruby (~> 1.0)
139
+ unicode-display_width (2.1.0)
140
+ xpath (3.2.0)
141
+ nokogiri (~> 1.8)
142
+ zeitwerk (2.6.0)
143
+
144
+ PLATFORMS
145
+ arm64-darwin-21
146
+ x86_64-linux
147
+
148
+ DEPENDENCIES
149
+ appraisal
150
+ byebug
151
+ capybara (~> 3)
152
+ combustion (~> 1.3)
153
+ rake (~> 13)
154
+ rspec-rails (~> 5)
155
+ rspec-viewcomponent!
156
+ standard (~> 1.3)
157
+ view_component!
158
+
159
+ BUNDLED WITH
160
+ 2.3.4
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2022 Simon Fish
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,107 @@
1
+ # RSpec::ViewComponent
2
+
3
+ RSpec::ViewComponent provides contexts that help you write clean one-line specs
4
+ for your components. This enables you to test that they respond as expected and
5
+ specify their function without the cruft of boilerplate.
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's Gemfile, ideally in the `test` group:
10
+
11
+ ```rb
12
+ gem 'rspec-viewcomponent'
13
+ ```
14
+
15
+ And then execute:
16
+
17
+ $ bundle install
18
+
19
+ Or install it yourself as:
20
+
21
+ $ gem install rspec-viewcomponent
22
+
23
+ ## Usage
24
+
25
+ Require the gem in your `spec_helper.rb`:
26
+
27
+ ```rb
28
+ require 'rspec-viewcomponent'
29
+ ```
30
+
31
+ Then, make the shared context available to component examples:
32
+
33
+ ```rb
34
+ RSpec.configure do |config|
35
+ config.include RSpec::ViewComponent::Context, type: :component
36
+ end
37
+ ```
38
+
39
+ It's suggested that you follow the patterns laid out in
40
+ `spec/viewcomponent/rspec/context_spec.rb` when testing your component.
41
+ Generally, you'll only need to test the rendered component unless you're reliant
42
+ on methods you call upon it. `RSpec::ViewComponent::Context` makes this
43
+ available as the `subject` of any tests by default, allowing you to write
44
+ one-line tests with matchers like `have_css` and `be_empty`:
45
+
46
+ ```rb
47
+ describe ExampleComponent do
48
+ let(:args) { ['red'] }
49
+ let(:content) { ->(_view_context = nil) { 'Hello World' } }
50
+
51
+ describe 'rendered component' do
52
+ it { is_expected.to have_css('p.red', text: 'Hello World') }
53
+
54
+ context 'with nil content' do
55
+ let(:content) { ->(view_context = nil) {} }
56
+
57
+ it { is_expected.to be_empty }
58
+ end
59
+ end
60
+ end
61
+ ```
62
+
63
+ As you can see there, the context also makes use of two variables defined with `let`:
64
+
65
+ - `args`, passed to the component upon initialize, e.g. `'red'` in the case of
66
+ `ExampleComponent.new('red')`. `kwargs` is also available for keyword arguments.
67
+ - `content`, passed to the component in a block when it's rendered, e.g.
68
+ `ExampleComponent.new.with_content('Hello World')` or
69
+
70
+ ```erb
71
+ <%= render ExampleComponent do %>
72
+ Hello World
73
+ <% end %>
74
+ ```
75
+
76
+ `component_instance` is also available, should you wish to test against the
77
+ component instance itself.
78
+
79
+ ## Development
80
+
81
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run
82
+ `rake spec` to run the tests.
83
+
84
+ To install this gem onto your local machine, run `bundle exec rake install`. To
85
+ release a new version, update the version number in `version.rb`, and then run
86
+ `bundle exec rake release`, which will create a git tag for the version, push
87
+ git commits and the created tag, and push the `.gem` file to
88
+ [rubygems.org](https://rubygems.org).
89
+
90
+ ## Contributing
91
+
92
+ Bug reports and pull requests are welcome on GitHub at
93
+ https://github.com/viewcomponent/rspec-viewcomponent. This project is intended to be
94
+ a safe, welcoming space for collaboration, and contributors are expected to
95
+ adhere to the [code of
96
+ conduct](https://github.com/viewcomponent/rspec-viewcomponent/blob/main/CODE_OF_CONDUCT.md).
97
+
98
+ ## License
99
+
100
+ The gem is available as open source under the terms of the [MIT
101
+ License](https://opensource.org/licenses/MIT).
102
+
103
+ ## Code of Conduct
104
+
105
+ Everyone interacting in the RSpec::ViewComponent project's codebases, issue
106
+ trackers, chat rooms and mailing lists is expected to follow the [code of
107
+ conduct](https://github.com/viewcomponent/rspec-viewcomponent/blob/main/CODE_OF_CONDUCT.md).
data/Rakefile ADDED
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "bundler/gem_tasks"
4
+ require "rspec/core/rake_task"
5
+
6
+ RSpec::Core::RakeTask.new(:spec)
7
+
8
+ require "standard/rake"
9
+
10
+ task default: %i[spec standard]
data/bin/console ADDED
@@ -0,0 +1,15 @@
1
+ #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
3
+
4
+ require "bundler/setup"
5
+ require "viewcomponent/rspec"
6
+
7
+ # You can add fixtures and/or initialization code here to make experimenting
8
+ # with your gem easier. You can also use a different console, if you like.
9
+
10
+ # (If you use this, don't forget to add pry to your Gemfile!)
11
+ # require "pry"
12
+ # Pry.start
13
+
14
+ require "irb"
15
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
data/config.ru ADDED
@@ -0,0 +1,9 @@
1
+ # frozen_string_literal: true
2
+
3
+ require "rubygems"
4
+ require "bundler"
5
+
6
+ Bundler.require :default, :development
7
+
8
+ Combustion.initialize! :all
9
+ run Combustion::Application
@@ -0,0 +1,2 @@
1
+ ---
2
+ BUNDLE_RETRY: "1"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "view_component", github: "github/view_component", branch: "fix-config-loading-where-vc-is-a-dependency"
6
+ gem "rails", "~> 6.0.0"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,11 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "view_component", github: "github/view_component", branch: "fix-config-loading-where-vc-is-a-dependency"
6
+ gem "rails", "~> 6.1.0"
7
+ gem "net-smtp", require: false
8
+ gem "net-imap", require: false
9
+ gem "net-pop", require: false
10
+
11
+ gemspec path: "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "view_component", github: "github/view_component", branch: "fix-config-loading-where-vc-is-a-dependency"
6
+ gem "rails", "~> 7.0.0"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "view_component", github: "github/view_component", branch: "fix-config-loading-where-vc-is-a-dependency"
6
+ gem "rails", github: "rails/rails", branch: "main"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,37 @@
1
+ require "active_support/concern"
2
+ module RSpec
3
+ module ViewComponent
4
+ module Context
5
+ extend ActiveSupport::Concern
6
+
7
+ included do
8
+ RSpec.shared_context "ViewComponent" do
9
+ subject do
10
+ render_inline component, &content
11
+ rendered_component
12
+ end
13
+
14
+ let(:component) do
15
+ described_class.new(
16
+ *(defined?(args) ? args : []),
17
+ **(defined?(kwargs) ? kwargs : {})
18
+ )
19
+ end
20
+ let(:content) { ->(_view_context = nil) {} }
21
+ let(:component_instance) do
22
+ rendered_content = content.call
23
+ rendered_content ? component.with_content(rendered_content) : component
24
+ end
25
+
26
+ matcher :be_rendered do
27
+ match do |actual|
28
+ expect(actual).to be_render
29
+ end
30
+ end
31
+ end
32
+
33
+ include_context "ViewComponent"
34
+ end
35
+ end
36
+ end
37
+ end
@@ -0,0 +1,7 @@
1
+ # frozen_string_literal: true
2
+
3
+ module RSpec
4
+ module ViewComponent
5
+ VERSION = "0.1.0"
6
+ end
7
+ end
@@ -0,0 +1,11 @@
1
+ # frozen_string_literal: true
2
+
3
+ require_relative "viewcomponent/version"
4
+ require_relative "viewcomponent/context"
5
+
6
+ module RSpec
7
+ module ViewComponent
8
+ class Error < StandardError; end
9
+ # Your code goes here...
10
+ end
11
+ end
@@ -0,0 +1,6 @@
1
+ module ViewComponent
2
+ module RSpec
3
+ VERSION: String
4
+ # See the writing guide of rbs: https://github.com/ruby/rbs#guides
5
+ end
6
+ end
metadata ADDED
@@ -0,0 +1,203 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: rspec-viewcomponent
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Simon Fish
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2022-08-16 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activesupport
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 5.0.0
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '8.0'
23
+ type: :runtime
24
+ prerelease: false
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: 5.0.0
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: '8.0'
33
+ - !ruby/object:Gem::Dependency
34
+ name: appraisal
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - ">="
38
+ - !ruby/object:Gem::Version
39
+ version: '0'
40
+ type: :development
41
+ prerelease: false
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - ">="
45
+ - !ruby/object:Gem::Version
46
+ version: '0'
47
+ - !ruby/object:Gem::Dependency
48
+ name: byebug
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - ">="
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
54
+ type: :development
55
+ prerelease: false
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - ">="
59
+ - !ruby/object:Gem::Version
60
+ version: '0'
61
+ - !ruby/object:Gem::Dependency
62
+ name: capybara
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '3'
68
+ type: :development
69
+ prerelease: false
70
+ version_requirements: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '3'
75
+ - !ruby/object:Gem::Dependency
76
+ name: combustion
77
+ requirement: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - "~>"
80
+ - !ruby/object:Gem::Version
81
+ version: '1.3'
82
+ type: :development
83
+ prerelease: false
84
+ version_requirements: !ruby/object:Gem::Requirement
85
+ requirements:
86
+ - - "~>"
87
+ - !ruby/object:Gem::Version
88
+ version: '1.3'
89
+ - !ruby/object:Gem::Dependency
90
+ name: rake
91
+ requirement: !ruby/object:Gem::Requirement
92
+ requirements:
93
+ - - "~>"
94
+ - !ruby/object:Gem::Version
95
+ version: '13'
96
+ type: :development
97
+ prerelease: false
98
+ version_requirements: !ruby/object:Gem::Requirement
99
+ requirements:
100
+ - - "~>"
101
+ - !ruby/object:Gem::Version
102
+ version: '13'
103
+ - !ruby/object:Gem::Dependency
104
+ name: rspec-rails
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - "~>"
108
+ - !ruby/object:Gem::Version
109
+ version: '5'
110
+ type: :development
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - "~>"
115
+ - !ruby/object:Gem::Version
116
+ version: '5'
117
+ - !ruby/object:Gem::Dependency
118
+ name: standard
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - "~>"
122
+ - !ruby/object:Gem::Version
123
+ version: '1.3'
124
+ type: :development
125
+ prerelease: false
126
+ version_requirements: !ruby/object:Gem::Requirement
127
+ requirements:
128
+ - - "~>"
129
+ - !ruby/object:Gem::Version
130
+ version: '1.3'
131
+ - !ruby/object:Gem::Dependency
132
+ name: view_component
133
+ requirement: !ruby/object:Gem::Requirement
134
+ requirements:
135
+ - - "~>"
136
+ - !ruby/object:Gem::Version
137
+ version: '2'
138
+ type: :development
139
+ prerelease: false
140
+ version_requirements: !ruby/object:Gem::Requirement
141
+ requirements:
142
+ - - "~>"
143
+ - !ruby/object:Gem::Version
144
+ version: '2'
145
+ description: Provides setup to prevent you writing excessive boilerplate in ViewComponent
146
+ tests.
147
+ email:
148
+ - si@mon.fish
149
+ executables: []
150
+ extensions: []
151
+ extra_rdoc_files: []
152
+ files:
153
+ - ".rspec"
154
+ - ".standard.yml"
155
+ - ".tool-versions"
156
+ - Appraisals
157
+ - CHANGELOG.md
158
+ - CODE_OF_CONDUCT.md
159
+ - Gemfile
160
+ - Gemfile.lock
161
+ - LICENSE.txt
162
+ - README.md
163
+ - Rakefile
164
+ - bin/console
165
+ - bin/setup
166
+ - config.ru
167
+ - gemfiles/.bundle/config
168
+ - gemfiles/rails_6.0.gemfile
169
+ - gemfiles/rails_6.1.gemfile
170
+ - gemfiles/rails_7.0.gemfile
171
+ - gemfiles/rails_head.gemfile
172
+ - lib/rspec/viewcomponent.rb
173
+ - lib/rspec/viewcomponent/context.rb
174
+ - lib/rspec/viewcomponent/version.rb
175
+ - sig/viewcomponent/rspec.rbs
176
+ homepage: https://github.com/viewcomponent/rspec-viewcomponent
177
+ licenses:
178
+ - MIT
179
+ metadata:
180
+ allowed_push_host: https://rubygems.org
181
+ homepage_uri: https://github.com/viewcomponent/rspec-viewcomponent
182
+ source_code_uri: https://github.com/viewcomponent/rspec-viewcomponent
183
+ changelog_uri: https://github.com/viewcomponent/rspec-viewcomponent
184
+ post_install_message:
185
+ rdoc_options: []
186
+ require_paths:
187
+ - lib
188
+ required_ruby_version: !ruby/object:Gem::Requirement
189
+ requirements:
190
+ - - ">="
191
+ - !ruby/object:Gem::Version
192
+ version: 2.6.0
193
+ required_rubygems_version: !ruby/object:Gem::Requirement
194
+ requirements:
195
+ - - ">="
196
+ - !ruby/object:Gem::Version
197
+ version: '0'
198
+ requirements: []
199
+ rubygems_version: 3.3.7
200
+ signing_key:
201
+ specification_version: 4
202
+ summary: RSpec helpers for ViewComponent tests
203
+ test_files: []