Skip to content
This repository has been archived by the owner on May 6, 2022. It is now read-only.

Commit

Permalink
Print status timestamps in UTC
Browse files Browse the repository at this point in the history
Otherwise when you run tests they may fail depending on the local
timezone. Not 100% sure if the user experience is better with local
times or UTC, but that can be considered in a follow-up.
  • Loading branch information
carolynvs-msft committed Jan 18, 2018
1 parent 5ed7c77 commit 70a0801
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
3 changes: 2 additions & 1 deletion cmd/svcat/output/output.go
Expand Up @@ -41,6 +41,7 @@ func formatStatusFull(condition string, conditionStatus v1beta1.ConditionStatus,
if status == "" {
return ""
}

message = strings.TrimRight(message, ".")
return fmt.Sprintf("%s - %s @ %s", status, message, timestamp)
return fmt.Sprintf("%s - %s @ %s", status, message, timestamp.UTC())
}
2 changes: 1 addition & 1 deletion cmd/svcat/testdata/output/describe-binding.txt
@@ -1,4 +1,4 @@
Name: ups-binding
Namespace: test-ns
Status: Ready - Injected bind result @ 2018-01-11 15:00:47 -0600 CST
Status: Ready - Injected bind result @ 2018-01-11 21:00:47 +0000 UTC
Instance: ups-instance
2 changes: 1 addition & 1 deletion cmd/svcat/testdata/output/describe-broker.txt
@@ -1,3 +1,3 @@
Name: ups-broker
URL: http://ups-broker-ups-broker.ups-broker.svc.cluster.local
Status: Ready - Successfully fetched catalog entries from broker @ 2018-01-11 14:53:31 -0600 CST
Status: Ready - Successfully fetched catalog entries from broker @ 2018-01-11 20:53:31 +0000 UTC
2 changes: 1 addition & 1 deletion cmd/svcat/testdata/output/describe-instance.txt
@@ -1,6 +1,6 @@
Name: ups-instance
Namespace: test-ns
Status: Ready - The instance was provisioned successfully @ 2018-01-11 14:59:47 -0600 CST
Status: Ready - The instance was provisioned successfully @ 2018-01-11 20:59:47 +0000 UTC
Class: user-provided-service
Plan: default

Expand Down

0 comments on commit 70a0801

Please sign in to comment.