Class: TestServer::GeneratorController

Inherits:
ApplicationController show all
Defined in:
app/controllers/test_server/generator_controller.rb

Instance Method Summary collapse

Methods included from WebHelper

#configure_caching, #encode, #generate_eicar, #generate_random_string, #generate_string

Instance Method Details

#indexObject



7
8
# File 'app/controllers/test_server/generator_controller.rb', line 7

def index
end

#xhrObject



10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'app/controllers/test_server/generator_controller.rb', line 10

def xhr
  add_breadcrumb I18n.t('views.generator.xhr.link'), :generator_xhr_path

  @urls = [ streaming_plain_url,
            streaming_eicar_url,
            streaming_random_url,
            string_plain_url,
            string_eicar_url,
            string_sleep_url,
            string_random_url,
            generator_xhr_url,
            "http://#{request.host_with_port}/static/plain.html" 
  ]

  @count   = params[:count]
  @url     = params[:url]
  @timeout = params[:timeout]
  @repeat  = params[:repeat]
end