Check-in [041a36ff2c]
Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
| Comment: | - try using rspec+insist |
|---|---|
| Downloads: | Tarball | ZIP archive | SQL archive |
| Timelines: | family | ancestors | descendants | both | trunk |
| Files: | files | file ages | folders |
| SHA1: |
041a36ff2c040bf01a2c9ed50846d5a0 |
| User & Date: | jls@semicomplete.com 2012-03-08 08:03:04 |
Context
|
2012-03-08
| ||
| 15:49 | - more work aligning the deb package class with the new API check-in: 0c28fb4f70 user: jls@semicomplete.com tags: trunk | |
| 08:03 | - try using rspec+insist check-in: 041a36ff2c user: jls@semicomplete.com tags: trunk | |
| 08:02 | move class methods to bottom check-in: eb6bfd58d7 user: jls@semicomplete.com tags: trunk | |
Changes
Changes to Gemfile.
1 2 3 | source :rubygems gemspec | < < < < < < | 1 2 3 | source :rubygems gemspec |
Changes to Gemfile.lock.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
PATH
remote: .
specs:
fpm (0.4.0)
backports (= 2.3.0)
cabin (~> 0.4.2)
json
GEM
remote: http://rubygems.org/
specs:
backports (2.3.0)
cabin (0.4.2)
json
fattr (2.2.1)
| > > > > | < | < < < < < > > > > > > > > < < | | | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
PATH
remote: .
specs:
fpm (0.4.0)
arr-pm
backports (= 2.3.0)
cabin (~> 0.4.2)
json
GEM
remote: http://rubygems.org/
specs:
arr-pm (0.0.2)
cabin (> 0)
backports (2.3.0)
cabin (0.4.2)
json
diff-lcs (1.1.3)
fattr (2.2.1)
insist (0.0.1)
cabin (> 0)
json (1.6.5)
rspec (2.8.0)
rspec-core (~> 2.8.0)
rspec-expectations (~> 2.8.0)
rspec-mocks (~> 2.8.0)
rspec-core (2.8.0)
rspec-expectations (2.8.0)
diff-lcs (~> 1.1.2)
rspec-mocks (2.8.0)
rush (0.6.7)
session
session (3.1.0)
fattr
PLATFORMS
ruby
DEPENDENCIES
fpm!
insist
rspec
rush
|
Changes to fpm.gemspec.
| ︙ | ︙ | |||
31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
# For reading and writing rpms
spec.add_dependency("arr-pm") # license: Apache 2
# For simple shell/file hackery in the tests.
# http://rush.heroku.com/rdoc/
spec.add_development_dependency("rush") # license: MIT
spec.files = files
spec.require_paths << "lib"
spec.bindir = "bin"
spec.executables << "fpm"
spec.executables << "fpm-npm"
spec.author = "Jordan Sissel"
spec.email = "jls@semicomplete.com"
spec.homepage = "https://github.com/jordansissel/fpm"
end
| > > > | 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# For reading and writing rpms
spec.add_dependency("arr-pm") # license: Apache 2
# For simple shell/file hackery in the tests.
# http://rush.heroku.com/rdoc/
spec.add_development_dependency("rush") # license: MIT
spec.add_development_dependency("rspec") # license: ???
spec.add_development_dependency("insist") # license: ???
spec.files = files
spec.require_paths << "lib"
spec.bindir = "bin"
spec.executables << "fpm"
spec.executables << "fpm-npm"
spec.author = "Jordan Sissel"
spec.email = "jls@semicomplete.com"
spec.homepage = "https://github.com/jordansissel/fpm"
end
|
Added spec/fpm/package/rpm_spec.rb.
> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 |
require "spec_setup"
require "fpm" # local
require "fpm/package/rpm" # local
require "fpm/package/dir" # local
require "rpm" # gem arr-pm
describe FPM::Package::RPM do
subject { FPM::Package::RPM.new }
before :each do
@target = Tempfile.new
end # before
after :each do
subject.cleanup
@target.close
end # after
describe "#output" do
context "basics" do
before :each do
end
it "should output a package with the correct name" do
subject.output(@target.path)
rpm = RPM::File.new(@target.path)
# TODO(sissel): verify rpm name vs subject.name
end
it "should output a package with the correct version"
it "should output a package with the correct iteration"
it "should output a package with the correct epoch"
it "should output a package with the correct dependencies"
end
end # describe FPM::Package::Dir
|
Changes to spec/fpm/package_spec.rb.
| ︙ | ︙ | |||
17 18 19 20 21 22 23 24 |
it "should allow setting the package name" do
name = "my-package"
subject.name = name
insist { subject.name } == name
end
end
end # describe FPM::Package
| > > > > > > > > > > > > > > > > > > > > > > > > > > > > > | 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 |
it "should allow setting the package name" do
name = "my-package"
subject.name = name
insist { subject.name } == name
end
end
describe "#version" do
it "should default to '1.0'" do
insist { subject.version } == "1.0"
end
it "should allow setting the package name" do
version = "hello"
subject.version = version
insist { subject.version } == version
end
end
describe "#architecture"
describe "#attributes"
describe "#category"
describe "#config_files"
describe "#conflicts"
describe "#dependencies"
describe "#description"
describe "#epoch"
describe "#iteration"
describe "#license"
describe "#maintainer"
describe "#provides"
describe "#replaces"
describe "#scripts"
describe "#url"
describe "#vendor"
end # describe FPM::Package
|
Deleted test/fpm/package/dir.rb.
|
| < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < < |