...

/

Challenge Solution: Log In

Challenge Solution: Log In

Let’s look at the solution for the Log In challenge.

Let’s look at the solution to the challenge.

Note: This isn’t the only way to implement the feature and pass the tests.

# This file is used by Rack-based servers to start the application.

require_relative "config/environment"

run Rails.application
Rails.application.load_server
Solution for the log in challenge

Explanation

Let’s break down the solution implemented above.

Define the test steps

We make the following changes to features/step_definitions/login_steps.rb:

  • Lines 1–3: ...