Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Transpositioned everything to Riot from Protest

  • Loading branch information...
commit 18c2367835eafcdcd3e81025787f3483095f79fb 1 parent c81aa36
@gus gus authored
View
2  Rakefile
@@ -9,10 +9,8 @@ task(:set_test_env) { ENV['RACK_ENV'] ||= 'test' }
desc "Run all tests"
task :test => [:set_test_env] do
- require 'protest'
$:.concat ['./lib', './test']
Dir.glob("./test/*_test.rb").each { |test| require test }
- Protest.report
end
task "test:shoulda" => [:set_test_env]
View
14 chicago.gemspec
@@ -1,14 +1,14 @@
Gem::Specification.new do |s|
s.name = "chicago"
- s.version = "0.3.4"
- s.date = "2009-10-02"
+ s.version = "0.3.5"
+ s.date = "2009-10-04"
s.summary = "Sinatra runtime and testing extensions used commonly by Thumblemonks"
s.email = %w[gus@gusg.us gabriel.gironda@gmail.com]
s.homepage = "http://github.com/thumblemonks/chicago/tree/master"
s.description = "Sinatra runtime and testing extensions used commonly by Thumblemonks. For example, :json_response, which turns an object into JSON and sets the content-type appropriately."
s.authors = %w[Justin\ Knowlden Gabriel\ Gironda]
- s.has_rdoc = false
+ s.has_rdoc = true
s.rdoc_options = ["--main", "README.markdown"]
s.extra_rdoc_files = ["README.markdown"]
@@ -20,9 +20,9 @@ Gem::Specification.new do |s|
lib/chicago.rb
lib/chicago/application.rb
lib/chicago/helpers.rb
- lib/chicago/protest.rb
- lib/chicago/protest/macros.rb
lib/chicago/responders.rb
+ lib/chicago/riot.rb
+ lib/chicago/riot/macros.rb
lib/chicago/shoulda.rb
lib/chicago/shoulda/sinatra.rb
]
@@ -33,6 +33,10 @@ Gem::Specification.new do |s|
test/helpers_test.rb
test/protest_macros_test.rb
test/responders_test.rb
+ test/shoulda_tests/application_test.rb
+ test/shoulda_tests/helpers_test.rb
+ test/shoulda_tests/responders_test.rb
+ test/shoulda_tests/test_helper.rb
test/test_helper.rb
]
end
View
1  lib/chicago/protest.rb
@@ -1 +0,0 @@
-require 'chicago/protest/macros'
View
1  lib/chicago/riot.rb
@@ -0,0 +1 @@
+require 'chicago/riot/macros'
View
6 lib/chicago/protest/macros.rb → lib/chicago/riot/macros.rb
@@ -1,7 +1,7 @@
require 'json'
module Chicago
- module Protest
+ module Riot
module Macros
def asserts_response_status(expected)
asserts("response status is #{expected}") { last_response.status }.equals(expected)
@@ -39,7 +39,7 @@ def asserts_redirected_to(expected_path)
asserts_location expected_path
end
end # Macros
- end # Protest
+ end # Riot
end # Chicago
-Protest::Context.instance_eval { include Chicago::Protest::Macros }
+Riot::Context.instance_eval { include Chicago::Riot::Macros }
View
2  test/protest_macros_test.rb
@@ -1,6 +1,6 @@
require 'test_helper'
-context "Protest Macros Test:" do
+context "Riot Macros Test:" do
setup do
mock_app {
helpers Sinatra::Chicago::Responders
View
6 test/test_helper.rb
@@ -1,4 +1,4 @@
-%w[ rubygems protest haml sass chicago rack/test chicago/protest ].each do |lib|
+%w[ rubygems riot haml sass chicago rack/test chicago/riot ].each do |lib|
require lib
end
@@ -20,6 +20,8 @@ def app
end
end
-class Protest::Situation
+class Riot::Situation
include Rack::Test::Methods
end
+
+at_exit { Riot.report }
Please sign in to comment.
Something went wrong with that request. Please try again.