Address staticcheck
failures for test/e2e/node/...
Fix the `staticcheck` failures for `test/e2e/node`. All of the staticcheck errors were for variables which were never used. When these values were `err`, we added processing for the errors. When they were values that were just never used, we stopped giving them a name.
This commit is contained in:
@@ -281,7 +281,9 @@ func getCPUStat(f *framework.Framework, host string) (usage, uptime float64) {
|
||||
lines := strings.Split(result.Stdout, "\n")
|
||||
|
||||
usage, err = strconv.ParseFloat(lines[0], 64)
|
||||
framework.ExpectNoError(err, "Cannot parse float for usage")
|
||||
uptime, err = strconv.ParseFloat(lines[1], 64)
|
||||
framework.ExpectNoError(err, "Cannot parse float for uptime")
|
||||
|
||||
// Convert from nanoseconds to seconds
|
||||
usage *= 1e-9
|
||||
|
Reference in New Issue
Block a user