| 
    Anklang-0.3.0.dev502+ga23511a1 anklang-0.3.0.dev502+ga23511a1
    
   ASE — Anklang Sound Engine (C++) 
   « « « Anklang Documentation  | 
 
#include "testing.hh"
Public Member Functions | |
| Timer (double deadline_in_secs=0) | |
| Create a Timer() instance, specifying an optional upper bound for test durations.   | |
| int64 | n_reps () const | 
| Number of benchmark repetitions to execute.   | |
| double | test_elapsed () const | 
| Seconds spent in benchmark()   | |
| double | min_elapsed () const | 
| Minimum time benchmarked for a callee() call.   | |
| double | max_elapsed () const | 
| Maximum time benchmarked for a callee() call.   | |
| template<typename Callee > | |
| double | benchmark (Callee callee) | 
Class for profiling benchmark tests. UseCase: Benchmarking function implementations, e.g. to compare sorting implementations.
Definition at line 39 of file testing.hh.
      
  | 
  explicit | 
Create a Timer() instance, specifying an optional upper bound for test durations.
Definition at line 26 of file testing.cc.
      
  | 
  virtual | 
Definition at line 30 of file testing.cc.
| double Ase::Test::Timer::benchmark | ( | Callee | callee | ) | 
| callee | A callable function or object. Method to benchmark the execution time of callee. | 
| double Ase::Test::Timer::max_elapsed | ( | ) | const | 
Maximum time benchmarked for a callee() call.
Definition at line 100 of file testing.cc.
References MAX, and std::vector::size().
| double Ase::Test::Timer::min_elapsed | ( | ) | const | 
Minimum time benchmarked for a callee() call.
Definition at line 91 of file testing.cc.
References MIN, and std::vector::size().
| int64 Ase::Test::Timer::n_reps | ( | ) | const | 
Number of benchmark repetitions to execute.
Definition at line 52 of file testing.hh.
| double Ase::Test::Timer::test_elapsed | ( | ) | const | 
Seconds spent in benchmark()
Definition at line 53 of file testing.hh.