public
Rubygem
Description: Gruff graphing library for Ruby
Homepage: http://gruff.rubyforge.org
Clone URL: git://github.com/topfunky/gruff.git
Create output directory on test runs.
Remove bullet graphs (going to branch)
topfunky (author)
Thu Mar 13 09:41:51 -0700 2008
commit  dd5cf3b4937ab0aedb9152fda2c7c6133f525f42
tree    c8d66cf703edc26dc7728436b36a06e2b6ae0f11
parent  71887cb331542cd77d08c5aefd26ef772b6462fa
...
3
4
5
 
6
7
 
 
 
8
9
10
...
76
77
78
79
 
80
81
82
...
3
4
5
6
7
8
9
10
11
12
13
14
...
80
81
82
 
83
84
85
86
0
@@ -3,8 +3,12 @@ $:.unshift(File.dirname(__FILE__) + "/../lib/")
0
 
0
 require 'test/unit'
0
 require 'gruff'
0
+require 'fileutils'
0
 # require 'test_timer'
0
 
0
+TEST_OUTPUT_DIR = File.dirname(__FILE__) + "/output"
0
+FileUtils.mkdir_p(TEST_OUTPUT_DIR)
0
+
0
 class GruffTestCase < Test::Unit::TestCase
0
 
0
   def setup
0
@@ -76,7 +80,7 @@ protected
0
   end
0
 
0
   def write_test_file(graph, filename)
0
- graph.write(File.dirname(__FILE__) + "/output/#{filename}")
0
+ graph.write([TEST_OUTPUT_DIR, filename].join("/"))
0
   end
0
 
0
   ##
...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
...
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
0
@@ -1,26 +1,26 @@
0
-require File.dirname(__FILE__) + "/gruff_test_case"
0
-
0
-class TestGruffBullet < GruffTestCase
0
-
0
- def setup
0
- @data_args = [75, 100, {
0
- :target => 80,
0
- :low => 50,
0
- :high => 90
0
- }]
0
- end
0
-
0
- def test_bullet_graph
0
- g = Gruff::Bullet.new
0
- g.title = "Monthly Revenue"
0
- g.data *@data_args
0
- g.write("test/output/bullet_greyscale.png")
0
- end
0
-
0
- def test_no_options
0
- g = Gruff::Bullet.new
0
- g.data 127, 150
0
- g.write("test/output/bullet_no_options.png")
0
- end
0
-
0
-end
0
+# require File.dirname(__FILE__) + "/gruff_test_case"
0
+#
0
+# class TestGruffBullet < GruffTestCase
0
+#
0
+# def setup
0
+# @data_args = [75, 100, {
0
+# :target => 80,
0
+# :low => 50,
0
+# :high => 90
0
+# }]
0
+# end
0
+#
0
+# def test_bullet_graph
0
+# g = Gruff::Bullet.new
0
+# g.title = "Monthly Revenue"
0
+# g.data *@data_args
0
+# g.write("test/output/bullet_greyscale.png")
0
+# end
0
+#
0
+# def test_no_options
0
+# g = Gruff::Bullet.new
0
+# g.data 127, 150
0
+# g.write("test/output/bullet_no_options.png")
0
+# end
0
+#
0
+# end

Comments

    No one has commented yet.