Sha256: 5d8c2fd5c4a8972d6f4404f7090097832ff835ca558a0065735ddc121310ec71
Contents?: true
Size: 752 Bytes
Versions: 3
Compression:
Stored size: 752 Bytes
Contents
require "spec_helper" describe RedboothRuby::Request::Info do describe "#url" do it "constructs the url" do info = RedboothRuby::Request::Info.new(:get, nil, "random", {id: 1} ) expect(info.url).to match /random/ end end describe "#path_with_params" do it "does nothing when no params" do info = RedboothRuby::Request::Info.new(:get, nil, "random", nil) path = "/path/to/someplace" expect(info.path_with_params(path, {})).to eq path end it "constructs the path with params" do info = RedboothRuby::Request::Info.new(:get, nil, "random", nil) path = "/path/to/someplace" expect(info.path_with_params(path, {random: "stuff"})).to eq "#{path}?random=stuff" end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
redbooth-ruby-0.0.5 | spec/redbooth-ruby/request/info_spec.rb |
redbooth-ruby-0.0.4 | spec/redbooth-ruby/request/info_spec.rb |
redbooth-ruby-0.0.3 | spec/redbooth-ruby/request/info_spec.rb |