mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-11-02 03:27:54 +00:00
UI: Fix flaky time-related tests (#19521)
This commit is contained in:
@@ -11,7 +11,7 @@ import { task } from 'ember-concurrency';
|
||||
import { waitFor } from '@ember/test-waiters';
|
||||
import { add } from 'date-fns';
|
||||
import errorMessage from 'vault/utils/error-message';
|
||||
|
||||
import timestamp from 'vault/utils/timestamp';
|
||||
/**
|
||||
* @module Credentials
|
||||
* CredentialsPage component is a child component to show the generate and view
|
||||
@@ -33,7 +33,7 @@ export default class CredentialsPageComponent extends Component {
|
||||
@tracked credentials;
|
||||
|
||||
get leaseExpiry() {
|
||||
return add(new Date(), { seconds: this.credentials.lease_duration });
|
||||
return add(timestamp.now(), { seconds: this.credentials.lease_duration });
|
||||
}
|
||||
|
||||
@action
|
||||
|
||||
Reference in New Issue
Block a user