Changeset 1167
- Timestamp:
- Aug 14, 2010, 3:01:50 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/0.8-stable/test/graph_test.cc
r1166 r1167 25 25 26 26 #include <cstdlib> 27 #include <ostream> 27 28 28 29 using namespace theplu::svndigest; 30 31 void test_graph(const std::string format, test::Suite& suite); 32 void test_graph__(const std::string format, test::Suite& suite); 29 33 30 34 int main(int argc, char* argv[]) … … 37 41 #endif 38 42 43 test_graph("png", suite); 44 test_graph("svg", suite); 45 test_graph("pdf", suite); 46 39 47 // FIXME: in 0.9pre replace with 40 48 // return suite.exit_statu(); … … 43 51 return EXIT_FAILURE; 44 52 } 53 54 55 void test_graph(const std::string format, test::Suite& suite) 56 { 57 suite.out() << "testing " << format << std::endl; 58 for (size_t i=0; i<20; ++i) 59 test_graph__(format, suite); 60 } 61 62 63 void test_graph__(const std::string format, test::Suite& suite) 64 { 65 std::string filename("plot."); 66 filename+=format; 67 Graph graph(filename, format); 68 graph.ymax(10); 69 graph.current_color(255, 0, 0); 70 std::vector<unsigned int> data(100,1); 71 graph.plot(data, "label", 1); 72 }
Note: See TracChangeset
for help on using the changeset viewer.