[PDK-400] Inconsistent time reporting for test unit with/without --parallel Created: 2017/08/09 Updated: 2018/11/29 Resolved: 2018/10/29
|Project:||Puppet Development Kit|
|Fix Version/s:||PDK 1.8.0|
|Reporter:||Austin Blatt||Assignee:||Tim Sharpe|
|Remaining Estimate:||Not Specified|
|Time Spent:||Not Specified|
|Original Estimate:||Not Specified|
pdk test unit and pdk test unit --parallel output consistent timing.
|Epic Link:||PDK Maintenance|
|Method Found:||Needs Assessment|
|Release Notes:||Bug Fix|
|Release Notes Summary:||The output of pdk execution duration from running a command normally versus running a command with the `parallel` flag was inconsistent. This fix makes the duration output consistent.|
|QA Risk Assessment:||Needs Assessment|
pdk test unit reports the time that rspec spends running tests. pdk test unit --parallel reports the total time rspec tests + file loading time. This results in --parallel reporting a few second run time on a new module, when without the flag it reports <0.5 seconds run time (but still takes a few seconds to finish).
We should probably output two times for rspec tests. The CPU time that the rspec tests spent running and the total time of execution. For example,
Evaluated 6 tests (system: 0.320675 seconds, real: 3.523 seconds): 0 failures, 0 pending.
|Comment by Bryan Jen [ 2018/10/18 ]|
Output from PDK 1.7.0
|Comment by Jean Bond [ 2018/11/26 ]|
Tim Sharpe, does this now report only the testing time? And does this apply to pdk commands generally, or just `pdk test unit` (and `pdk validate`? )?
|Comment by Bryan Jen [ 2018/11/26 ]|
Jean Bond this now reports the wall time of PDK's execution of the command instead of the time rspec took to evaluate the examples.