chartspec 0.0.2 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/chartspec/version.rb +1 -1
- data/lib/chartspec.rb +2 -2
- metadata +1 -1
data/lib/chartspec/version.rb
CHANGED
data/lib/chartspec.rb
CHANGED
|
@@ -25,7 +25,7 @@ module Chartspec
|
|
|
25
25
|
@db = SQLite3::Database.new( ENV["CHARTSPEC_DB"] || "tmp/chartspec.sqlite3" )
|
|
26
26
|
@title = ENV["CHARTSPEC_TITLE"]
|
|
27
27
|
@name = ENV["CHARTSPEC_NAME"]
|
|
28
|
-
@db.execute( "CREATE TABLE IF NOT EXISTS specs(id INTEGER PRIMARY KEY, file TEXT,
|
|
28
|
+
@db.execute( "CREATE TABLE IF NOT EXISTS specs(id INTEGER PRIMARY KEY, file TEXT, name TEXT, duration NUMERIC, measured_at DATETIME);" )
|
|
29
29
|
end
|
|
30
30
|
|
|
31
31
|
def start(notification)
|
|
@@ -91,7 +91,7 @@ module Chartspec
|
|
|
91
91
|
template = ERB.new File.new(File.expand_path("../../templates/chartspec.html.erb", __FILE__)).read, nil, "%"
|
|
92
92
|
template.result(binding)
|
|
93
93
|
|
|
94
|
-
File.open("tmp/chartspec.html", "w") do |file|
|
|
94
|
+
File.open(ENV["CHARTSPEC_HTML"] || "tmp/chartspec.html", "w") do |file|
|
|
95
95
|
file.puts template.result(binding)
|
|
96
96
|
end
|
|
97
97
|
end
|