Skip to content

Add Request Specs #21

@venetya

Description

@venetya

They have to be controller tests now??

http://blog.bigbinary.com/2016/04/19/changes-to-test-controllers-in-rails-5.html
n Rails 5, controller tests expect to receive URL instead of action. Otherwise test will throw exception URI::InvalidURIError: bad URI.
This isn't working either:

test/controllers/routes_controller_test.rb:4:in `<top (required)>': superclass mismatch for class RoutesControllerTest (TypeError)

READ this:

http://rspec.info/blog/2016/07/rspec-3-5-has-been-released/

require 'test_helper'
require 'minitest/autorun'

class RoutesControllerTest < ActionDispatch::IntegrationTest

  def test_index
    get places_url
    assert_response :success
  end
end

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions