Sha256: ae06bc7e6bee26bf94564edf74aff8d61bca99db2f708e991dce0d787d2e7915

Contents?: true

Size: 1.55 KB

Versions: 3

Compression:

Stored size: 1.55 KB

Contents

/**
  @module ember
*/
import { helpers, registerHelper, registerAsyncHelper, unregisterHelper } from './test/helpers';
import { onInjectHelpers } from './test/on_inject_helpers';
import TestPromise, { promise, resolve } from './test/promise';
import { checkWaiters, registerWaiter, unregisterWaiter } from './test/waiters';

import { getAdapter, setAdapter } from './test/adapter';

/**
  This is a container for an assortment of testing related functionality:

  * Choose your default test adapter (for your framework of choice).
  * Register/Unregister additional test helpers.
  * Setup callbacks to be fired when the test helpers are injected into
    your application.

  @class Test
  @namespace Ember
  @public
*/
const Test = {
  /**
    Hash containing all known test helpers.

    @property _helpers
    @private
    @since 1.7.0
  */
  _helpers: helpers,

  registerHelper,
  registerAsyncHelper,
  unregisterHelper,
  onInjectHelpers,
  Promise: TestPromise,
  promise,
  resolve,
  registerWaiter,
  unregisterWaiter,
  checkWaiters,
};

/**
 Used to allow ember-testing to communicate with a specific testing
 framework.

 You can manually set it before calling `App.setupForTesting()`.

 Example:

 ```javascript
 Ember.Test.adapter = MyCustomAdapter.create()
 ```

 If you do not set it, ember-testing will default to `Ember.Test.QUnitAdapter`.

 @public
 @for Ember.Test
 @property adapter
 @type {Class} The adapter to be used.
 @default Ember.Test.QUnitAdapter
*/
Object.defineProperty(Test, 'adapter', {
  get: getAdapter,
  set: setAdapter,
});

export default Test;

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
discourse-ember-source-3.6.0.0 dist/es/ember-testing/lib/test.js
discourse-ember-source-3.5.1.1 dist/es/ember-testing/lib/test.js
discourse-ember-source-3.5.1.0 dist/dist/es/ember-testing/lib/test.js