Test.meta Method

Specifies custom test metadata.

test.meta( name, value ) → this
test.meta( metadata ) → this
Parameter Type Description
name String The name of the metadata entry.
value String The value of the metadata entry.
metadata Object Key-value pairs.

Users can embed custom metadata into fixture and test definitions. Use the fixture.meta method to specify custom fixture metadata. Read the Metadata Guide to learn more about this capability.

test('My test', async () => {
    /* ... */
}).meta('key1', 'value1');
test('My test', async () => {
    /* ... */
}).meta({ key1: 'value1', key2: 'value2', key3: 'value3' });