We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4f74b9a commit fbb38c3Copy full SHA for fbb38c3
test/testQuery.cxx
@@ -40,6 +40,17 @@ BOOST_AUTO_TEST_CASE(timeStampVerify)
40
BOOST_CHECK(diffZone < 1); // 1s
41
}
42
43
+BOOST_AUTO_TEST_CASE(queryPerformance)
44
+{
45
+ auto influxdb = influxdb::InfluxDBFactory::Get("http://localhost:8086?db=test");
46
+ auto t1 = std::chrono::high_resolution_clock::now();
47
+ auto points = influxdb->query("SELECT * from test WHERE host = 'localhost'");
48
+ BOOST_CHECK(points.size() >= 3);
49
+ auto t2 = std::chrono::high_resolution_clock::now();
50
+ double duration = std::chrono::duration_cast<std::chrono::microseconds>(t2 - t1).count();
51
+ BOOST_CHECK(duration < 20000);
52
+}
53
+
54
BOOST_AUTO_TEST_CASE(failedQuery1)
55
{
56
auto influxdb = influxdb::InfluxDBFactory::Get("http://localhost:8086?db=test");
0 commit comments