fix format duration rounding days error (#582)

* fix format duration rounding days error
* added tests

Signed-off-by: Sebastian Malton <smalton@mirantis.com>

Co-authored-by: Sebastian Malton <smalton@mirantis.com>
This commit is contained in:
Sebastian MaltonandSebastian Malton authored and GitHub committed 2020-07-15 09:45:52 -04:00
1 parent 55687b7d35
commit 4bd29a6d88
6 files changed
+91 -22

No files matched your search

-1
View File
@@ -1,5 +1,4 @@
import { CoreV1Api, KubeConfig } from "@kubernetes/client-node"
import http from "http"
import { ServerOptions } from "http-proxy"
import * as url from "url"
import logger from "./logger"
+1 -1
View File
@@ -125,7 +125,7 @@ export class Kubectl {
}
try {
const { stdout, stderr } = await promiseExec(`"${this.path}" version --client=true -o json`)
const { stdout } = await promiseExec(`"${this.path}" version --client=true -o json`)
const output = JSON.parse(stdout)
let version: string = output.clientVersion.gitVersion
if (version[0] === 'v') {