Commit 6ff449e
Changed files (3)
app/controllers/sessions_controller.rb
@@ -0,0 +1,2 @@
+class SessionsController < ApplicationController
+end
config/routes.rb
@@ -3,7 +3,7 @@ Rails.application.routes.draw do
# See how all your routes lay out with "rake routes".
# You can have the root of your site routed with "root"
- # root 'welcome#index'
+ root 'sessions#new'
# Example of regular route:
# get 'products/:id' => 'catalog#view'
spec/routing/route_routing_spec.rb
@@ -0,0 +1,7 @@
+require 'rails_helper'
+
+describe "root route" do
+ it 'routes to the login page' do
+ expect(get: '/').to route_to(controller: 'sessions', action: 'new')
+ end
+end