Sha256: bcdd8382d709439a082bc85f1cc0a440fff5f284bad78025e0ce67e48fb99951
Contents?: true
Size: 736 Bytes
Versions: 1
Compression:
Stored size: 736 Bytes
Contents
require "spec_helper" describe Redbooth::Request::Info do describe "#url" do it "constructs the url" do info = Redbooth::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 = Redbooth::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 = Redbooth::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
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
redbooth-ruby-0.0.2 | spec/redbooth/request/info_spec.rb |