mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-08-07 09:49:07 +00:00
Merge pull request #22147 from inkless/master
[ember-mocha] Adding context, suite to mocha export
This commit is contained in:
@@ -3,7 +3,7 @@ import {
|
||||
setResolver, setupAcceptanceTest, setupComponentTest,
|
||||
setupModelTest, setupTest
|
||||
} from 'ember-mocha';
|
||||
import { describe, it, beforeEach, afterEach, before, after } from 'mocha';
|
||||
import { context, describe, it, beforeEach, afterEach, before, after } from 'mocha';
|
||||
import chai = require('chai');
|
||||
import Ember from "ember";
|
||||
import hbs from 'htmlbars-inline-precompile';
|
||||
@@ -127,6 +127,14 @@ describe('setupTest', function() {
|
||||
});
|
||||
});
|
||||
|
||||
// testing context
|
||||
describe('for test suite A', function() {
|
||||
context('when trying method foo', function() {
|
||||
it('should test correctly', function() {
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
// if you don't have a custom resolver, do it like this:
|
||||
setResolver(Ember.DefaultResolver.create());
|
||||
|
||||
|
||||
1
types/ember-mocha/index.d.ts
vendored
1
types/ember-mocha/index.d.ts
vendored
@@ -65,6 +65,7 @@ declare module 'mocha' {
|
||||
|
||||
// re-export mocha globals as named exports
|
||||
export const describe: Mocha.IContextDefinition;
|
||||
export const context: Mocha.IContextDefinition;
|
||||
export const it: Mocha.ITestDefinition;
|
||||
export const setup: mochaSetup;
|
||||
export const teardown: mochaTeardown;
|
||||
|
||||
Reference in New Issue
Block a user