Module: Testrail::CommandHelper

Included in:
Request
Defined in:
lib/testrail/command_helper.rb

Instance Method Summary collapse

Instance Method Details

#build_url(command, ids = nil) ⇒ Object



3
4
5
6
7
8
9
10
# File 'lib/testrail/command_helper.rb', line 3

def build_url(command, ids = nil)
  command = Testrail.config.server + Testrail.config.api_path + command
  unless ids.nil?
    ids = '/' + [ids].flatten.join('/')
    command += ids
  end
  command + key
end