Module: Gridinit::Jmeter::Helper
- Included in:
- AccessLogSampler, AggregateGraph, AggregateReport, Ajp13Sampler, AssertionResults, AuthManager, BeanShellPreProcessor, BeanshellAssertion, BeanshellListener, BeanshellPostprocessor, BeanshellPreprocessor, BeanshellSampler, BeanshellTimer, BsfAssertion, BsfListener, BsfPostprocessor, BsfPreprocessor, BsfSampler, BsfTimer, CacheManager, CompareAssertion, ComparisonAssertionVisualizer, ConstantThroughputTimer, ConstantTimer, CookieManager, Counter, CounterConfig, CssjqueryExtractor, CsvDataSetConfig, DebugPostprocessor, DebugSampler, DistributionGraphalpha, DurationAssertion, ForeachController, FtpRequest, FtpRequestDefaults, GCConsoleStatusLogger, GCLatenciesOverTime, GCResponseCodesPerSecond, GCResponseTimesDistribution, GCResponseTimesOverTime, GCResponseTimesPercentiles, GCTransactionsPerSecond, GaussianRandomTimer, GenerateSummaryResults, GraphResults, GraphVisualizer, HeaderManager, HtmlAssertion, HtmlLinkParser, HtmlParameterMask, HttpAuthorizationManager, HttpCacheManager, HttpCookieManager, HttpHeaderManager, HttpRequest, HttpRequestDefaults, HttpSampler, HttpUrlRewritingModifier, IfController, IncludeController, InterleaveController, JavaRequest, JavaRequestDefaults, JdbcConnectionConfiguration, JdbcPostprocessor, JdbcPreprocessor, JdbcRequest, JmsPointtopoint, JmsPublisher, JmsSubscriber, Jsr223Assertion, Jsr223Listener, Jsr223Postprocessor, Jsr223Preprocessor, Jsr223Sampler, Jsr223Timer, JunitRequest, KeystoreConfiguration, LDAPExtSampler, LdapExtendedRequest, LdapExtendedRequestDefaults, LdapRequest, LdapRequestDefaults, LoginConfigElement, LoopController, MailReaderSampler, MailerVisualizer, Md5hexAssertion, ModuleController, MonitorResults, OnceOnly, OnceOnlyController, OsProcessSampler, PoissonRandomTimer, RandomController, RandomOrderController, RandomVariable, RandomVariableConfig, RecordingController, RegexExtractor, RegexUserParameters, RegularExpressionExtractor, RequestDefaults, ResponseAssertion, ResponseTimeGraph, ResponseTimeGraphVisualizer, ResultStatusActionHandler, RuntimeController, SaveResponsesToAFile, SimpleConfigElement, SimpleController, SimpleDataWriter, SmimeAssertion, SmtpSampler, SoapxmlrpcRequest, SplineVisualizer, StatVisualizer, SummaryReport, SwitchController, SynchronizingTimer, TableVisualizer, TcpSampler, TcpSamplerConfig, TestAction, TestPlan, ThreadGroup, Throughput, ThroughputController, ThroughputShapingTimer, Transaction, TransactionController, UniformRandomTimer, UserDefinedVariable, UserDefinedVariables, UserParameters, ViewResultsFullVisualizer, ViewResultsInTable, ViewResultsTree, WhileController, XmlAssertion, XmlSchemaAssertion, XpathAssertion, XpathExtractor
- Defined in:
- lib/gridinit-jmeter/helpers/dsl_helper.rb
Instance Method Summary collapse
Instance Method Details
#enabled(params) ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/gridinit-jmeter/helpers/dsl_helper.rb', line 11 def enabled(params) #default to true unless explicitly set to false if params.has_key?(:enabled) && params[:enabled] == false 'false' else 'true' end end |
#update(params) ⇒ Object
4 5 6 7 8 9 |
# File 'lib/gridinit-jmeter/helpers/dsl_helper.rb', line 4 def update(params) params.each do |name, value| node = @doc.children.xpath("//*[contains(@name,\"#{name.to_s}\")]") node.first.content = value unless node.empty? end end |