Add a logic error that our tests miss

❮ Back Next ❯

Task

Steps

class LimericksController < ApplicationController

  before_action :authenticate_user!, except: [:index]
  before_action :require_permission, except: [:index, :new, :create]

  def index
    @limericks = Limerick.take(2)
    render :index
  end

  ...
rails test -v
Running 1 tests in a single process (parallelization threshold is 50)
Run options: -v --seed 389

# Running:

LimericksControllerTest#test_should_get_index = 2.11 s = .

Finished in 2.112802s, 0.4733 runs/s, 0.9466 assertions/s.
1 runs, 2 assertions, 0 failures, 0 errors, 0 skips

❮ Back Next ❯