Class: Gridinit::Jmeter::UserDefinedVariable

Inherits:
Object
  • Object
show all
Includes:
Helper
Defined in:
lib/gridinit-jmeter/config/user_defined_variable.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Helper

#enabled, #update

Constructor Details

#initialize(params = {}) ⇒ UserDefinedVariable

Returns a new instance of UserDefinedVariable.



7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# File 'lib/gridinit-jmeter/config/user_defined_variable.rb', line 7

def initialize(params={})
  @doc = Nokogiri::XML(<<-EOF.strip_heredoc)
    <Arguments guiclass="ArgumentsPanel" testclass="Arguments" testname="User Defined Variables" enabled="true">
      <collectionProp name="Arguments.arguments">
        <elementProp name="testguid" elementType="Argument">
          <stringProp name="Argument.name"></stringProp>
          <stringProp name="Argument.value"></stringProp>
          <stringProp name="Argument.metadata">=</stringProp>
        </elementProp>
      </collectionProp>
      <stringProp name="TestPlan.comments"></stringProp>
    </Arguments>
  EOF
  update params
end

Instance Attribute Details

#docObject

Returns the value of attribute doc.



5
6
7
# File 'lib/gridinit-jmeter/config/user_defined_variable.rb', line 5

def doc
  @doc
end