Sha256: 775245274fa86def99096a49be9c5af3c0b3bac0a165a4901efbd06ec819f4f8
Contents?: true
Size: 1019 Bytes
Versions: 7
Compression:
Stored size: 1019 Bytes
Contents
# encoding: utf-8 module TestServer module App class StringController < ApplicationController before do param :no_cache, Boolean, default: false param :must_revalidate, Boolean, default: false param :max_age, Integer param :base64, Boolean, default: false configure_caching(params) end get '/' do redirect to('/default/') end get '/default/?:count?' do param :count, Integer, default: 1 encode do generate_string(params[:count]) end end get '/eicar/' do encode do generate_eicar.join end end get '/sleep/?:count?' do param :count, Integer, default: 120 sleep params[:count] encode do generate_string(1) end end get '/random/?:count?' do param :count, Integer, default: 10 encode do generate_random_string(params[:count]) end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems