Sha256: 15cf7e076a158c59100ede31012641d2a63defda7b20c6da1f6896de623a1d85
Contents?: true
Size: 899 Bytes
Versions: 5
Compression:
Stored size: 899 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + '../../helper') require 'cgi' class Rwiki::TestApp < Test::Unit::TestCase include Rack::Test::Methods def app Rwiki::App end context 'on GET to /' do setup { get '/' } should 'respond with success' do assert last_response.ok? end end context 'on GET to /nodes' do setup { get '/nodes', :path => '.' } should 'respond with success' do assert last_response.ok? end end context 'on GET to /node' do context 'for non-existing page' do setup { get '/node', :path => './non-existing.txt' } should 'respond with error' do assert_equal 500, last_response.status end end context 'for existing page' do setup { get '/node', :path => './home.txt' } should 'respond with success' do assert last_response.ok? end end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
rwiki-0.2.4 | test/rwiki/test_app.rb |
rwiki-0.2.3 | test/rwiki/test_app.rb |
rwiki-0.2.2 | test/rwiki/test_app.rb |
rwiki-0.2.1 | test/rwiki/test_app.rb |
rwiki-0.1.3 | test/rwiki/test_app.rb |