From 66d8808c98856feae7d5a2d5acfc955110fb126d Mon Sep 17 00:00:00 2001 From: Phips Peter Date: Tue, 12 May 2015 11:57:21 -0700 Subject: [PATCH] Adding test for new mocha API --- mocha/mocha-tests.ts | 29 ++++++++++++++++++++++++++++- 1 file changed, 28 insertions(+), 1 deletion(-) diff --git a/mocha/mocha-tests.ts b/mocha/mocha-tests.ts index dffd86e44..f90fefaf9 100644 --- a/mocha/mocha-tests.ts +++ b/mocha/mocha-tests.ts @@ -24,6 +24,18 @@ function test_context() { }); } +function test_suite() { + suite('some context', () => { }); + + suite.only('some context', () => { }); + + suite.skip('some context', () => { }); + + suite('some context', function() { + this.timeout(2000); + }); +} + function test_it() { it('does something', () => { }); @@ -39,6 +51,21 @@ function test_it() { }); } +function test_test() { + + test('does something', () => { }); + + test('does something', (done) => { done(); }); + + test.only('does something', () => { }); + + test.skip('does something', () => { }); + + test('does something', function () { + this.timeout(2000); + }); +} + function test_before() { before(() => { }); @@ -221,4 +248,4 @@ function test_run_withOnComplete() { instance.run((failures: number): void => { console.log(failures); }); -} \ No newline at end of file +}