Skip to content
Permalink
Browse files

refactor(ngScenario): use Date.now() for get current Time

Closes #10579
  • Loading branch information
袴田 俊輔 authored and pkozlowski-opensource committed Dec 26, 2014
1 parent d224fe8 commit 3616b9b07ced8cccb755f0d156cf39f58d334b53
Showing with 3 additions and 3 deletions.
  1. +3 −3 src/ngScenario/ObjectModel.js
@@ -114,7 +114,7 @@ angular.scenario.ObjectModel = function(runner) {
});

function complete(item) {
item.endTime = new Date().getTime();
item.endTime = Date.now();
item.duration = item.endTime - item.startTime;
item.status = item.status || 'success';
}
@@ -188,7 +188,7 @@ angular.scenario.ObjectModel.prototype.getSpec = function(id) {
angular.scenario.ObjectModel.Spec = function(id, name, definitionNames) {
this.id = id;
this.name = name;
this.startTime = new Date().getTime();
this.startTime = Date.now();
this.steps = [];
this.fullDefinitionName = (definitionNames || []).join(' ');
};
@@ -234,7 +234,7 @@ angular.scenario.ObjectModel.Spec.prototype.setStatusFromStep = function(step) {
*/
angular.scenario.ObjectModel.Step = function(name) {
this.name = name;
this.startTime = new Date().getTime();
this.startTime = Date.now();
};

/**

0 comments on commit 3616b9b

Please sign in to comment.
You can’t perform that action at this time.