Class: RSpec::Rails::HyperShortcut::RequestPair
- Inherits:
-
Object
- Object
- RSpec::Rails::HyperShortcut::RequestPair
- Defined in:
- lib/rspec/rails/extra/routing/hyper_shortcut/request_pair.rb
Instance Method Summary collapse
-
#initialize(method, path) ⇒ RequestPair
constructor
A new instance of RequestPair.
- #to_hash ⇒ Object
- #to_s ⇒ Object
Constructor Details
#initialize(method, path) ⇒ RequestPair
Returns a new instance of RequestPair.
3 4 5 6 |
# File 'lib/rspec/rails/extra/routing/hyper_shortcut/request_pair.rb', line 3 def initialize(method,path) @method = method @path = path end |
Instance Method Details
#to_hash ⇒ Object
8 9 10 |
# File 'lib/rspec/rails/extra/routing/hyper_shortcut/request_pair.rb', line 8 def to_hash {@method => @path} end |
#to_s ⇒ Object
12 13 14 |
# File 'lib/rspec/rails/extra/routing/hyper_shortcut/request_pair.rb', line 12 def to_s "#{@method.to_s.upcase} #{@path}" end |