Created
January 9, 2013 06:14
-
-
Save Trindaz/4491059 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
describe("d1", function(){ | |
function step1(){ | |
describe("A test description", function(){ | |
it("A test it", function(done){ | |
step2(); | |
done(); | |
}) | |
}) | |
}; | |
function step2(){ | |
describe("A test description 2", function(){ | |
it("A test it 2", function(done){ | |
step3(); | |
done(); | |
}) | |
}) | |
} | |
function step3(){ | |
describe("A test description 3", function(){ | |
it("A test it 3", function(done){ | |
done(); | |
}) | |
}) | |
} | |
step1(); | |
}); | |
describe("d2", function(){ | |
var currentStep = 0; | |
var steps = [ | |
function(){ | |
describe("A test description (array)", function(){ | |
it("A test it (array)", function(done){ | |
currentStep++; | |
steps[currentStep](); | |
done(); | |
}) | |
}) | |
}, | |
function(){ | |
describe("A test description (array) 2", function(){ | |
it("A test it (array) 2", function(done){ | |
done(); | |
}) | |
}) | |
} | |
] | |
steps[currentStep](); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment