Skip to content

Commit

Permalink
updated rspec and gem infrastructure
Browse files Browse the repository at this point in the history
  • Loading branch information
pelle committed Nov 19, 2010
1 parent 7d4da6a commit c7eeea1
Show file tree
Hide file tree
Showing 18 changed files with 111 additions and 78 deletions.
25 changes: 4 additions & 21 deletions .gitignore
@@ -1,21 +1,4 @@
## MAC OS
.DS_Store

## TEXTMATE
*.tmproj
tmtags

## EMACS
*~
\#*
.\#*

## VIM
*.swp

## PROJECT::GENERAL
coverage
rdoc
pkg

## PROJECT::SPECIFIC
pkg/*
*.gem
.bundle
.rvmrc
3 changes: 3 additions & 0 deletions .rspec
@@ -0,0 +1,3 @@
--require fuubar
--format Fuubar
--color
4 changes: 4 additions & 0 deletions Gemfile
@@ -0,0 +1,4 @@
source "http://rubygems.org"

# Specify your gem's dependencies in opentransact.gemspec
gemspec
52 changes: 52 additions & 0 deletions Gemfile.lock
@@ -0,0 +1,52 @@
PATH
remote: .
specs:
opentransact (0.0.2)
oauth (~> 0.4.4)

GEM
remote: http://rubygems.org/
specs:
configuration (1.1.0)
diff-lcs (1.1.2)
fakeweb (1.3.0)
fuubar (0.0.2)
rspec (~> 2.0)
rspec-instafail (~> 0.1.4)
ruby-progressbar (~> 0.0.9)
growl (1.0.3)
guard (0.2.2)
open_gem (~> 1.4.2)
thor (~> 0.14.3)
guard-rspec (0.1.8)
guard (>= 0.2.0)
launchy (0.3.7)
configuration (>= 0.0.5)
rake (>= 0.8.1)
oauth (0.4.4)
open_gem (1.4.2)
launchy (~> 0.3.5)
rake (0.8.7)
rspec (2.1.0)
rspec-core (~> 2.1.0)
rspec-expectations (~> 2.1.0)
rspec-mocks (~> 2.1.0)
rspec-core (2.1.0)
rspec-expectations (2.1.0)
diff-lcs (~> 1.1.2)
rspec-instafail (0.1.4)
rspec-mocks (2.1.0)
ruby-progressbar (0.0.9)
thor (0.14.4)

PLATFORMS
ruby

DEPENDENCIES
fakeweb
fuubar
growl
guard-rspec
oauth (~> 0.4.4)
opentransact!
rspec (~> 2.1.0)
8 changes: 8 additions & 0 deletions Guardfile
@@ -0,0 +1,8 @@
# A sample Guardfile
# More info at http://github.com/guard/guard#readme

guard 'rspec', :version => 2 do
watch('^spec/(.*)_spec.rb')
watch('^lib/(.*)\.rb') { |m| "spec/#{m[1]}_spec.rb" }
watch('^spec/spec_helper.rb') { "spec" }
end
49 changes: 2 additions & 47 deletions Rakefile
@@ -1,47 +1,2 @@
require 'rubygems'
require 'rake'

begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "opentransact"
gem.summary = %Q{OpenTransact client for Ruby}
gem.description = %Q{OpenTransact client for Ruby}
gem.email = "pelle@stakeventures.com"
gem.homepage = "http://opentransact.github.com"
gem.authors = ["Pelle Braendgaard"]
gem.add_dependency "oauth", ">=0.3.6"
gem.add_development_dependency "rspec", ">= 1.2.9"
gem.add_development_dependency "yard", ">= 0"
gem.add_development_dependency "fakeweb", ">= 0"
# gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
end
Jeweler::GemcutterTasks.new
rescue LoadError
puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
end

require 'spec/rake/spectask'
Spec::Rake::SpecTask.new(:spec) do |spec|
spec.libs << 'lib' << 'spec'
spec.spec_files = FileList['spec/**/*_spec.rb']
end

Spec::Rake::SpecTask.new(:rcov) do |spec|
spec.libs << 'lib' << 'spec'
spec.pattern = 'spec/**/*_spec.rb'
spec.rcov = true
end

task :spec => :check_dependencies

task :default => :spec

begin
require 'yard'
YARD::Rake::YardocTask.new
rescue LoadError
task :yardoc do
abort "YARD is not available. In order to run yardoc, you must: sudo gem install yard"
end
end
require 'bundler'
Bundler::GemHelper.install_tasks
5 changes: 0 additions & 5 deletions lib/open_transact.rb

This file was deleted.

6 changes: 5 additions & 1 deletion lib/opentransact.rb
@@ -1 +1,5 @@
require 'open_transact'
require "opentransact/server"
require "opentransact/asset"
require "opentransact/client"
module OpenTransact
end
File renamed without changes.
File renamed without changes.
File renamed without changes.
3 changes: 3 additions & 0 deletions lib/opentransact/version.rb
@@ -0,0 +1,3 @@
module OpenTransact
VERSION = "0.0.2"
end
28 changes: 28 additions & 0 deletions opentransact.gemspec
@@ -0,0 +1,28 @@
# -*- encoding: utf-8 -*-
$:.push File.expand_path("../lib", __FILE__)
require "opentransact/version"

Gem::Specification.new do |s|
s.name = "opentransact"
s.version = OpenTransact::VERSION
s.platform = Gem::Platform::RUBY
s.authors = ["Pelle Braendgaard"]
s.email = ["pelle@stakeventures.com"]
s.homepage = "http://opentransact.org"
s.summary = %q{TODO: OpenTransact client for Ruby}
s.description = %q{TODO: OpenTransact client for Ruby}

s.rubyforge_project = "opentransact"

s.files = `git ls-files`.split("\n")
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
s.require_paths = ["lib"]

s.add_development_dependency "rspec", "~> 2.1.0"
s.add_development_dependency "fakeweb"
s.add_development_dependency "fuubar"
s.add_development_dependency "guard-rspec"
s.add_development_dependency "growl"
s.add_dependency "oauth", "~> 0.4.4"
end
File renamed without changes.
File renamed without changes.
File renamed without changes.
1 change: 0 additions & 1 deletion spec/spec.opts

This file was deleted.

5 changes: 2 additions & 3 deletions spec/spec_helper.rb
Expand Up @@ -2,9 +2,8 @@
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
require 'opentransact'
require 'fakeweb'
require 'spec'
require 'spec/autorun'
require 'rspec'

Spec::Runner.configure do |config|
RSpec::Runner.configure do |config|
FakeWeb.allow_net_connect = false
end

0 comments on commit c7eeea1

Please sign in to comment.