Sha256: f9d4fc43eff43af9efc88f1491f04f3c14921915e48f050a5cba88ef576314c0
Contents?: true
Size: 986 Bytes
Versions: 4
Compression:
Stored size: 986 Bytes
Contents
require "spec_helper" describe Rico do before :each do RiakHelpers.reset! end describe ".configure" do it "accepts a namespace" do Rico.configure do |r| r.namespace = "myapp" end Rico.namespace.should eql "myapp" end it "accepts a hash of options" do Rico.configure do |r| r.options = { http_port: 5151 } end Rico.options.should eql({ http_port: 5151 }) end end describe ".bucket" do describe "namespacing" do it "supports an empty namespace" do Rico.namespace = nil Rico.bucket("users").name.should eql "users" end it "supports a single namespace" do Rico.namespace = "development" Rico.bucket("users").name.should eql "development:users" end it "supports multiple namespaces" do Rico.namespace = ["myapp", "development"] Rico.bucket("users").name.should eql "myapp:development:users" end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
rico-0.5.0 | spec/rico_spec.rb |
rico-0.4.0 | spec/rico_spec.rb |
rico-0.3.0 | spec/rico_spec.rb |
rico-0.2.0 | spec/rico_spec.rb |