UNPKG

543 BJavaScriptView Raw
1'use strict'
2
3var Yadda = require('yadda')
4var steps = require('./steps')
5
6Yadda.plugins.mocha.StepLevelPlugin.init()
7
8new Yadda.FeatureFileSearch('./tests/features').each(function(file) {
9
10 global.featureFile(file, function(feature) {
11
12 var yadda = Yadda.createInstance(steps)
13
14 global.scenarios(feature.scenarios, function(scenario) {
15 var ctx = { options: {} }
16 global.steps(scenario.steps, function(step, done) {
17 yadda.run(step, { ctx: ctx }, done)
18 })
19 })
20 })
21})
\No newline at end of file