1
0
mirror of https://github.com/projekteuler/projekteuler.git synced 2025-12-10 08:46:41 +01:00
projekteuler/test/integration/translator_flow_test.rb

20 lines
490 B
Ruby

require 'test_helper'
class TranslatorFlowTest < ActionDispatch::IntegrationTest
test "can view a problem" do
get '/problems/1'
assert_response :success
assert_select "h1", "First title Problem 1"
end
test "can login via github" do
get '/users/auth/github'
assert_response :redirect
follow_redirect!
follow_redirect!
assert_response :success
assert controller.user_signed_in?
assert_equal "translator", controller.current_user.name
end
end