Skip to content
Browse files

move to rspec 2.1.0

  • Loading branch information...
1 parent 26aeb78 commit c50a51725547a876bf59be510d8e40efdf6afb7e @atmos committed Nov 23, 2010
Showing with 14 additions and 33 deletions.
  1. +5 −5 Gemfile
  2. +4 −4 Rakefile
  3. +4 −4 spec/helpers/matchers.rb
  4. +1 −1 spec/spec_helper.rb
  5. +0 −19 spec/units/app_spec.rb
View
10 Gemfile
@@ -11,10 +11,10 @@ end
group :test do
gem 'rake'
- gem 'webrat', '~>0.7.0'
- gem 'rspec', '~>1.2.9', :require => 'spec'
- gem 'rack-test', '~>0.5.0', :require => 'rack/test'
+ gem 'rspec', '~>2.1.0', :require => 'rspec'
+ gem 'webrat', '~>0.7.0'
gem 'randexp'
- gem 'addressable', :require => 'addressable/uri'
- gem 'ParseTree', :require => 'parse_tree'
+ gem 'rack-test', '~>0.5.0', :require => 'rack/test'
+ gem 'ParseTree', :require => 'parse_tree'
+ gem 'addressable', :require => 'addressable/uri'
end
View
8 Rakefile
@@ -49,9 +49,9 @@ end
task :default => [:spec]
-require 'spec/rake/spectask'
+require 'rspec/core/rake_task'
desc "Run specs"
-Spec::Rake::SpecTask.new do |t|
- t.spec_files = FileList['spec/**/*_spec.rb']
- t.spec_opts = %w(-fp --color)
+RSpec::Core::RakeTask.new do |t|
+ t.pattern = FileList['spec/**/*_spec.rb']
+ t.rspec_opts = %w(-fp --color)
end
View
8 spec/helpers/matchers.rb
@@ -24,7 +24,7 @@ def be_a_login_form
class IdentityProviderDocument
include Webrat::Methods
include Webrat::Matchers
- include Spec::Matchers
+ include RSpec::Matchers
def matches?(target)
target.headers['Content-Type'].should eql('application/xrds+xml')
@@ -43,7 +43,7 @@ def be_an_identity_provider
end
class RedirectToConsumer
- include Spec::Matchers
+ include RSpec::Matchers
include Webrat::Methods
include Webrat::Matchers
@@ -83,7 +83,7 @@ def be_a_redirect_to_the_consumer(consumer_url, username)
end
class ReturnAnOpenIDAssociateResponse
- include Spec::Matchers
+ include RSpec::Matchers
include Webrat::Methods
include Webrat::Matchers
@@ -116,7 +116,7 @@ def be_an_openid_associate_response(openid_session)
end
class ReturnAnOpenIDImmediateResponse
- include Spec::Matchers
+ include RSpec::Matchers
include Webrat::Methods
include Webrat::Matchers
View
2 spec/spec_helper.rb
@@ -23,7 +23,7 @@ def self.authenticated?(username, password)
end
end
-Spec::Runner.configure do |config|
+Rspec.configure do |config|
def app
Hancock::TestApp.app
end
View
19 spec/units/app_spec.rb
@@ -1,19 +0,0 @@
-require File.expand_path(File.dirname(__FILE__)+'/../spec_helper')
-
-describe Hancock::SSO::App do
- describe "default sreg parameters" do
- it "returns sane defaults" do
- pending do
- Hancock::SSO::App.sreg_params.should eql([:id, :email, :first_name, :last_name, :internal, :admin])
- end
- end
- end
- describe "setting the default sreg parameters" do
- it "returns the values set by the method" do
- pending do
- Hancock::SSO::App.sreg_params = [:email, :birthdate, :gender]
- Hancock::SSO::App.sreg_params.should eql([:email, :birthdate, :gender])
- end
- end
- end
-end

0 comments on commit c50a517

Please sign in to comment.
Something went wrong with that request. Please try again.