Skip to content

Latest commit

 

History

History
43 lines (33 loc) · 1.27 KB

File metadata and controls

43 lines (33 loc) · 1.27 KB
layout page-api
title QUnit.config.modules
excerpt List of defined test modules.
groups
config
extension
redirect_from
/config/modules/
version_added 1.16.0

List of defined test modules.

type `Array` (read-only)

The QUnit.config.modules property is exposed for use by plugins and other integrations. It returns an array of internal Module objects, one for each call to QUnit.module().

Before accessing this property, wait for the QUnit.on('runStart') event, or use a QUnit.begin() callback.

Module object

The following properties are considered stable and public:

property description
name (string) Module name, as passed to QUnit.module().
moduleId (string) Hashed identifier, for the QUnit.config.moduleId filter.

Other properties may change without notice. When possible, use QUnit.on or event callbacks instead.

Example

QUnit.on('runStart', () => {
  console.log(QUnit.config.modules.map(mod => mod.name));
});