doc/BigBench/Configuration.html in bigbench-0.0.4 vs doc/BigBench/Configuration.html in bigbench-0.0.5

- old
+ new

@@ -64,12 +64,10 @@ <ul class="link-list"> <li><a href="#method-c-config">::config</a> - <li><a href="#method-c-configure-3D">::configure=</a> - <li><a href="#method-c-reset-21">::reset!</a> </ul> </nav> @@ -107,26 +105,24 @@ <li><a href="../BigBench/Bot.html">BigBench::Bot</a> <li><a href="../BigBench/Configuration.html">BigBench::Configuration</a> - <li><a href="../BigBench/Configuration/Config.html">BigBench::Configuration::Config</a> - - <li><a href="../BigBench/Configuration/InvalidOptions.html">BigBench::Configuration::InvalidOptions</a> - <li><a href="../BigBench/Executor.html">BigBench::Executor</a> - <li><a href="../BigBench/Executor/InvalidCommand.html">BigBench::Executor::InvalidCommand</a> + <li><a href="../BigBench/Executor/Executable.html">BigBench::Executor::Executable</a> <li><a href="../BigBench/Fragment.html">BigBench::Fragment</a> <li><a href="../BigBench/Fragment/Fragment.html">BigBench::Fragment::Fragment</a> <li><a href="../BigBench/Output.html">BigBench::Output</a> <li><a href="../BigBench/PostProcessor.html">BigBench::PostProcessor</a> + <li><a href="../BigBench/PostProcessor/Context.html">BigBench::PostProcessor::Context</a> + <li><a href="../BigBench/PostProcessor/Environment.html">BigBench::PostProcessor::Environment</a> <li><a href="../BigBench/PostProcessor/Environment/Appearings.html">BigBench::PostProcessor::Environment::Appearings</a> <li><a href="../BigBench/PostProcessor/Environment/AttributeCluster.html">BigBench::PostProcessor::Environment::AttributeCluster</a> @@ -153,10 +149,12 @@ <li><a href="../BigBench/PostProcessor/Statistics.html">BigBench::PostProcessor::Statistics</a> <li><a href="../BigBench/PostProcessor/Test.html">BigBench::PostProcessor::Test</a> + <li><a href="../BigBench/PostProcessor/TestPretty.html">BigBench::PostProcessor::TestPretty</a> + <li><a href="../BigBench/Runner.html">BigBench::Runner</a> <li><a href="../BigBench/Runner/NoBenchmarksDefined.html">BigBench::Runner::NoBenchmarksDefined</a> <li><a href="../BigBench/Store.html">BigBench::Store</a> @@ -186,16 +184,16 @@ <div id="description" class="description"> <p>The configuration is configured in the test reciepts and looks like this:</p> -<pre class="ruby"><span class="ruby-constant">BigBench</span>.<span class="ruby-identifier">configure</span> = { - :<span class="ruby-identifier">duration</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value">10</span>.<span class="ruby-identifier">seconds</span>, - :<span class="ruby-identifier">output</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-string">&quot;test.ljson&quot;</span>, - :<span class="ruby-identifier">users</span> =<span class="ruby-operator">&gt;</span> <span class="ruby-value">20</span>, - :<span class="ruby-identifier">basic_auth</span> =<span class="ruby-operator">&gt;</span> [<span class="ruby-string">'username'</span>, <span class="ruby-string">'secret'</span>] -} +<pre class="ruby"><span class="ruby-constant">BigBench</span>.<span class="ruby-identifier">configure</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">config</span><span class="ruby-operator">|</span> + <span class="ruby-identifier">config</span>.<span class="ruby-identifier">duration</span> = <span class="ruby-value">10</span>.<span class="ruby-identifier">seconds</span>, + <span class="ruby-identifier">config</span>.<span class="ruby-identifier">output</span> = <span class="ruby-string">&quot;test.ljson&quot;</span>, + <span class="ruby-identifier">config</span>.<span class="ruby-identifier">users</span> = <span class="ruby-value">20</span>, + <span class="ruby-identifier">config</span>.<span class="ruby-identifier">basic_auth</span> = [<span class="ruby-string">'username'</span>, <span class="ruby-string">'secret'</span>] +<span class="ruby-keyword">end</span> </pre> <p>Single values can be set and retrieved like this:</p> <pre class="ruby"><span class="ruby-constant">BigBench</span>.<span class="ruby-identifier">config</span>.<span class="ruby-identifier">duration</span> = <span class="ruby-value">20</span>.<span class="ruby-identifier">minutes</span> @@ -236,10 +234,23 @@ + <!-- Constants --> + <section id="constants-list" class="section"> + <h3 class="section-header">Constants</h3> + <dl> + + <dt id="DEFAULTS">DEFAULTS + + <dd class="description"> + + + </dl> + </section> + <!-- Methods --> @@ -256,18 +267,18 @@ </div> <div class="method-description"> - <p>Returns the current config object</p> + <p>Returns tor creates the config object</p> <div class="method-source-code" id="config-source"> - <pre><span class="ruby-comment"># File lib/bigbench/configuration.rb, line 76</span> + <pre><span class="ruby-comment"># File lib/bigbench/configuration.rb, line 46</span> <span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">config</span> - <span class="ruby-ivar">@config</span> + <span class="ruby-identifier">@@config</span> <span class="ruby-operator">||=</span> <span class="ruby-constant">OpenStruct</span>.<span class="ruby-identifier">new</span>(<span class="ruby-constant">DEFAULTS</span>) <span class="ruby-keyword">end</span></pre> </div><!-- config-source --> </div> @@ -275,45 +286,10 @@ </div><!-- config-method --> - <div id="method-c-configure-3D" class="method-detail "> - - <div class="method-heading"> - <span class="method-name">configure=</span><span - class="method-args">(config)</span> - <span class="method-click-advice">click to toggle source</span> - </div> - - - <div class="method-description"> - - <p>Configures the benchmarks with a hash. If the config methods are not -present yet, they are added to the config object</p> - - - - <div class="method-source-code" id="configure-3D-source"> - <pre><span class="ruby-comment"># File lib/bigbench/configuration.rb, line 67</span> -<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">configure=</span>(<span class="ruby-identifier">config</span>) - <span class="ruby-identifier">raise</span> <span class="ruby-string">&quot;Config must be a Hash&quot;</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">config</span>.<span class="ruby-identifier">is_a?</span>(<span class="ruby-constant">Hash</span>) - <span class="ruby-identifier">config</span>.<span class="ruby-identifier">each</span> { <span class="ruby-operator">|</span><span class="ruby-identifier">option</span>, <span class="ruby-identifier">value</span><span class="ruby-operator">|</span> - <span class="ruby-ivar">@config</span>.<span class="ruby-identifier">class</span>.<span class="ruby-identifier">add_option</span>(<span class="ruby-identifier">option</span>) - <span class="ruby-ivar">@config</span>.<span class="ruby-identifier">send</span> <span class="ruby-node">&quot;#{option}=&quot;</span>, <span class="ruby-identifier">value</span> - } -<span class="ruby-keyword">end</span></pre> - </div><!-- configure-3D-source --> - - </div> - - - - - </div><!-- configure-3D-method --> - - <div id="method-c-reset-21" class="method-detail "> <div class="method-heading"> <span class="method-name">reset!</span><span class="method-args">()</span> @@ -326,12 +302,12 @@ <p>Resets the config object</p> <div class="method-source-code" id="reset-21-source"> - <pre><span class="ruby-comment"># File lib/bigbench/configuration.rb, line 81</span> + <pre><span class="ruby-comment"># File lib/bigbench/configuration.rb, line 39</span> <span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier">reset!</span> - <span class="ruby-ivar">@config</span> = <span class="ruby-constant">Config</span>.<span class="ruby-identifier">new</span> + <span class="ruby-identifier">@@config</span> = <span class="ruby-keyword">nil</span> <span class="ruby-keyword">end</span></pre> </div><!-- reset-21-source --> </div>