bin/cobench in cobench-0.0.9 vs bin/cobench in cobench-0.0.10

- old
+ new

@@ -100,11 +100,14 @@ type = "Cobench::#{name.capitalize}" loog.info("Reading #{u}/#{name}...") require_relative f m = type.split('::').reduce(Module, :const_get).new(api, u, opts) if opts.dry? - measures = [{ title: 'Mock', total: Random.new.rand(100), href: 'https://github.com/' }] + measures = [ + { title: 'Test1', total: Random.new.rand(100), href: 'https://github.com/' }, + { title: 'Test2', total: Random.new.rand(100), href: 'https://github.com/' } + ] else measures = m.take(loog) end measures.each do |d| data[u][d[:title]] = { total: d[:total], href: d[:href] } @@ -139,10 +142,10 @@ xml = builder.to_xml loog.debug(xml) File.write(index, xml) loog.debug("XML saved to #{index} (#{File.size(index)} bytes)") xslt = Nokogiri::XSLT(File.read(File.join(__dir__, '../assets/index.xsl'))) - html = xslt.transform(Nokogiri::XML(xml)) + html = xslt.transform(Nokogiri::XML(xml), 'version' => "'#{Cobench::VERSION}'") loog.debug(html) front = File.join(home, 'index.html') File.write(front, html) loog.debug("HTML saved to #{front} (#{File.size(front)} bytes)") rescue StandardError => e