lib/teuton/project/readme/dsl.rb in teuton-2.1.3 vs lib/teuton/project/readme/dsl.rb in teuton-2.1.4

- old
+ new

@@ -29,25 +29,25 @@ def goto(host = :localhost, args = {}) unless host == :localhost b = {} a = "#{host}_ip".to_sym - if @config[:global][a].nil? && (not @setted_params.include?(a)) + if @config[:global][a].nil? && !@setted_params.include?(a) @cases_params << a end b[:ip] = @config[:global][a] if @config[:global][a] b[:ip] = @setted_params[a] if @setted_params[a] a = "#{host}_username".to_sym - if @config[:global][a].nil? && (not @setted_params.include?(a)) + if @config[:global][a].nil? && !@setted_params.include?(a) @cases_params << a end b[:username] = @config[:global][a] if @config[:global][a] b[:username] = @setted_params[a] if @setted_params[a] a = "#{host}_password".to_sym - if @config[:global][a].nil? && (not @setted_params.include?(a)) + if @config[:global][a].nil? && !@setted_params.include?(a) @cases_params << a end b[:password] = @config[:global][a] if @config[:global][a] b[:password] = @setted_params[a] if @setted_params[a] @@ -60,11 +60,11 @@ def run(command, args = {}) args[:exec] = command goto(:localhost, args) end - def expect(_cond, args = {}) + def expect(_cond, _args = {}) @current[:actions] << @action result.reset end alias expect_any expect alias expect_none expect @@ -90,9 +90,10 @@ def gett(value) a = get(value) return "[#{value}](\#required-params)" if @cases_params.include? value return "[#{value}](\#created-params)" if @setted_params[value] + "[#{a}](\#global-params)" if @global_params.include? value end def set(key, value) @setted_params[key] = value