nfengine
nfengine copied to clipboard
Write performance tests for nfCommon and nfCore
Apart from unit tests there should be also performance and stress tests.
- can be written using gtest, but the results (timings, etc.) should be displayed in clear way (maybe html report)
- should measure memory usage also
We have a VS project named "nfCorePerfTest", but I was wondering if we could avoid this projects explosion - there should be also stress tests, which gives 6 test project total (nfCommon/nfCorePerfTest vs. unit/perf/stress). Why not just have 2 projects: nfCoreTest + nfCommonTest and create unit/perf/stress within them? All unit test cases names would start with "Unit" prefix, etc., so we could easily filter them. Example names: "UnitThreadPool.Simple", "StressSceneManager.Blah".
So, as discussed, IMO having a performance test in a separate project is just an easier way to organise this. Unit tests should execute in short time, since they are used for verification, whereas perf/stress tests will execute for a much longer time in order to provide reliable data and are needed only in specific cases.
However, we can keep stress tests together with perf tests. After all, stress testing modules is some kind of a performance test ;)