Re:Software development topics I've changed my mind on after...
by johnnyanmac on Wednesday February 05, 2025 @06:33PM
(#42956919)
It will vary immensely on how readable the actual code base it, but what comes to mind:
1. what units? I was just caught in this with a function with a timeout. I had to look at the docs to find out this was actually in nanoseconds (stuff like this is why I came more around to verbose parameter names).
2. what's the function of the timer?
3. (potential code smell) Do I need to manually increment such a timer for the test? is the time library a necessary part of the test (or perhaps what we testing)?
1. what units? I was just caught in this with a function with a timeout. I had to look at the docs to find out this was actually in nanoseconds (stuff like this is why I came more around to verbose parameter names).
2. what's the function of the timer?
3. (potential code smell) Do I need to manually increment such a timer for the test? is the time library a necessary part of the test (or perhaps what we testing)?