aboutsummaryrefslogtreecommitdiffstats
path: root/src/scenario/Runner.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/scenario/Runner.js')
-rw-r--r--src/scenario/Runner.js7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/scenario/Runner.js b/src/scenario/Runner.js
index 55360592..a8b23f83 100644
--- a/src/scenario/Runner.js
+++ b/src/scenario/Runner.js
@@ -91,6 +91,7 @@ angular.scenario.Runner.prototype.run = function(ui, application, specRunnerClas
});
angular.foreach(angular.scenario.dsl, function(fn, key) {
self.$window[key] = function() {
+ var line = callerFile(3);
var scope = angular.scope(runner);
// Make the dsl accessible on the current chain
@@ -103,10 +104,12 @@ angular.scenario.Runner.prototype.run = function(ui, application, specRunnerClas
// Make these methods work on the current chain
scope.addFuture = function() {
- return angular.scenario.SpecRunner.prototype.addFuture.apply(scope, arguments);
+ Array.prototype.push.call(arguments, line);
+ return specRunnerClass.prototype.addFuture.apply(scope, arguments);
};
scope.addFutureAction = function() {
- return angular.scenario.SpecRunner.prototype.addFutureAction.apply(scope, arguments);
+ Array.prototype.push.call(arguments, line);
+ return specRunnerClass.prototype.addFutureAction.apply(scope, arguments);
};
return scope.dsl[key].apply(scope, arguments);