diff options
author | Mark Janes <mark.a.janes@intel.com> | 2017-01-20 10:54:01 -0800 |
---|---|---|
committer | Mark Janes <mark.a.janes@intel.com> | 2017-06-19 14:04:50 -0700 |
commit | 98105513860e95118eb9ab9dfbfe199d811a1013 (patch) | |
tree | 1a59f78df96aec2ed4da93031cb172e84e8161cb /retrace/daemon/test | |
parent | 8f2d6c46b715cdf30a89c63bc3e54d5499cad6ea (diff) |
ApiLog: update interfaces for multiple render selection
Stubs implementation to match the required interfaces.
Diffstat (limited to 'retrace/daemon/test')
-rw-r--r-- | retrace/daemon/test/retrace_daemon_test.cpp | 12 | ||||
-rw-r--r-- | retrace/daemon/test/retrace_file_transfer_test.cpp | 5 | ||||
-rw-r--r-- | retrace/daemon/test/retrace_metrics_test.cpp | 3 |
3 files changed, 14 insertions, 6 deletions
diff --git a/retrace/daemon/test/retrace_daemon_test.cpp b/retrace/daemon/test/retrace_daemon_test.cpp index 33b70fc0..8ecf73e2 100644 --- a/retrace/daemon/test/retrace_daemon_test.cpp +++ b/retrace/daemon/test/retrace_daemon_test.cpp @@ -87,7 +87,8 @@ class NullCallback : public OnFrameRetrace { void onMetrics(const MetricSeries &metricData, ExperimentId experimentCount, SelectionId selectionCount) {} - void onApi(RenderId renderId, + void onApi(SelectionId selectionCount, + RenderId renderId, const std::vector<std::string> &api_calls) { calls = api_calls; } @@ -183,9 +184,14 @@ TEST_F(RetraceTest, ApiCalls) { FrameRetrace rt; get_md5(test_file, &md5, &fileSize); rt.openFile(test_file, md5, fileSize, 7, &cb); - rt.retraceApi(RenderId(-1), &cb); + RenderSelection sel; + sel.series.push_back(RenderSequence(RenderId(-1), + RenderId(-1))); + rt.retraceApi(sel, &cb); EXPECT_GT(cb.calls.size(), 0); - rt.retraceApi(RenderId(1), &cb); + sel.series.back().begin = RenderId(1); + sel.series.back().end = RenderId(2); + rt.retraceApi(sel, &cb); EXPECT_GT(cb.calls.size(), 0); } diff --git a/retrace/daemon/test/retrace_file_transfer_test.cpp b/retrace/daemon/test/retrace_file_transfer_test.cpp index ca1fcffa..c1d38cad 100644 --- a/retrace/daemon/test/retrace_file_transfer_test.cpp +++ b/retrace/daemon/test/retrace_file_transfer_test.cpp @@ -86,7 +86,7 @@ class FileTransfer : public IFrameRetrace { const std::string &geom, const std::string &comp, OnFrameRetrace *callback) {} - void retraceApi(RenderId renderId, + void retraceApi(const RenderSelection &selection, OnFrameRetrace *callback) {} }; @@ -119,7 +119,8 @@ class FileTransferCB : public OnFrameRetrace { ExperimentId experimentCount, bool status, const std::string &errorString) {} - void onApi(RenderId renderId, + void onApi(SelectionId selectionCount, + RenderId renderId, const std::vector<std::string> &api_calls) {} void onError(const std::string &message) {} bool m_needUpload; diff --git a/retrace/daemon/test/retrace_metrics_test.cpp b/retrace/daemon/test/retrace_metrics_test.cpp index 705b984a..f0b2fcde 100644 --- a/retrace/daemon/test/retrace_metrics_test.cpp +++ b/retrace/daemon/test/retrace_metrics_test.cpp @@ -70,7 +70,8 @@ class MetricsCallback : public OnFrameRetrace { experiment_count = experimentCount; selection_count = selectionCount; } - void onApi(RenderId renderId, + void onApi(SelectionId selectionCount, + RenderId renderId, const std::vector<std::string> &api_calls) {} void onError(const std::string &message) {} std::vector<MetricId> ids; |