# frozen_string_literal: true

require_relative 'base_controller'
require_relative '../models/test'

# / (top-level) routes
class IndexController < BaseController

  get '/' do
    tests = Test.reverse(:updated_at).limit(10).all()

    erb :'index/index', locals: {
      title: 'Dashboard',
      tests: tests
    }
  end

end
