Sha256: a8da758d89920f60f8f91f2e994f20b35d38d8826e6bbc7c840f0a3e1bfeab8c
Contents?: true
Size: 1.42 KB
Versions: 7
Compression:
Stored size: 1.42 KB
Contents
module JmeterPerf class DSL # DSL method synonymous with the JMeter Element TransactionController # @param params [Hash] Parameters for the TransactionController element (default: `{}`). # @yield block to attach to the TransactionController element # @return [JmeterPerf::TransactionController], a subclass of JmeterPerf::DSL that can be chained with other DSL methods. # @see https://github.com/jlurena/jmeter_perf/wiki/1.-DSL-Documentation#transactioncontroller def transaction_controller(params = {}, &) node = TransactionController.new(params) attach_node(node, &) end class TransactionController attr_accessor :doc include JmeterPerf::Helpers::XmlDocumentUpdater def initialize(params = {}) testname = params.is_a?(Array) ? "TransactionController" : (params[:name] || "TransactionController") @doc = Nokogiri::XML(JmeterPerf::Helpers::String.strip_heredoc( <<~EOS <TransactionController guiclass="TransactionControllerGui" testclass="TransactionController" testname="#{testname}" enabled="true"> <boolProp name="TransactionController.parent">true</boolProp> <boolProp name="TransactionController.includeTimers">false</boolProp> </TransactionController> EOS )) update params update_at_xpath params if params.is_a?(Hash) && params[:update_at_xpath] end end end end
Version data entries
7 entries across 7 versions & 1 rubygems