hotstuff
hotstuff copied to clipboard
feat: add support for printing the zero value from test.Name
Currently, the test.Name helper function will not print entries with the zero value, including for bool=false, int=0, and empty strings etc.
However, it is sometimes desirable to print the subtest names with /field=zero-value as well, e.g., /PayloadSize=0.
We should find a way to "encode" which of the fields should print the zero-value.
One simple idea is to add a prefix like _ to the field names like this:
name := test.Name([]string{"_AutoScale", "_Score"}, test.AutoScale, test.score)
The _ would not be printed, but it should print this: /AutoScale=false/Score=0.
If someone has other ideas, please let me know.
PS: The / separator between parameters is used by standard tools like benchstat.