Sha256: bef76e8e1ebd60b9ca5fc54d3bdfc2a0a4627108562db5ee994448960446b70f
Contents?: true
Size: 1007 Bytes
Versions: 1
Compression:
Stored size: 1007 Bytes
Contents
require "spec_helper" module Bickle describe Repository do it "returns repo name when valid given" do repository = Repository.new("rails/rails") repository.name.should == "rails/rails" end it "allows to use a shortened version of repository name" do repository = Repository.new("rails") repository.name.should == "rails/rails" end it "raises error if name contains invalid characters" do expect do repository = Repository.new("ra ls") end.to raise_error(InvalidRepositoryNameError) expect do repository = Repository.new("rails/)(&@#") end.to raise_error(InvalidRepositoryNameError) end it "allows underscores and dashes in the repo name" do expect do repository = Repository.new("foo-bar/foo_bar") end.not_to raise_error(InvalidRepositoryNameError) expect do repository = Repository.new("foo_bar") end.not_to raise_error(InvalidRepositoryNameError) end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
bickle-0.0.1 | spec/repository_spec.rb |