Skip to content

Commit

Permalink
Import describe and it from global scope instead of mocha
Browse files Browse the repository at this point in the history
Watch mode breaks otherwise. See
mochajs/mocha#956.
  • Loading branch information
alexanderchr committed May 4, 2016
1 parent 83d1691 commit 06f436a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion test/insertCssSpec.js
Expand Up @@ -8,10 +8,11 @@
*/

import jsdom from 'jsdom';
import { describe, it } from 'mocha';
import { expect } from 'chai';
import insertCss from '../src/insertCss';

const { describe, it } = global;

global.document = jsdom.jsdom('<!doctype html><html><body></body></html>');
global.window = document.parentWindow;

Expand Down
2 changes: 1 addition & 1 deletion test/withStylesSpec.js
Expand Up @@ -9,11 +9,11 @@

/* eslint-disable react/prefer-stateless-function */

import { describe, it } from 'mocha';
import { expect } from 'chai';
import React, { createClass, Component } from 'react';
import withStyles from '../src/withStyles';

const { describe, it } = global;

describe('withStyles(ComposedComponent, ...styles)', () => {
class Passthrough extends Component {
Expand Down

0 comments on commit 06f436a

Please sign in to comment.