chartspec 0.0.2 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- 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
|