Docs (4.0.0)
Tests

class TestScope

A class that represents a test scope, containing a number of test cases.

class TestScope

Description

Test scopes are created using calls to describe(). The TestScope instance is passed to the definition function immediately, so it can use its own TestScope methods — for example to set callbacks that run before/after every test in the scope.

Example

describe("My test scope", (scope) => {
  scope.beforeEach(() => {
    // ... this runs before each test
  });

  test("My test case", () => {});
});

Static Members

Instance Members