Interface TestItemCollection

Collection of test items, found in TestItem.children and TestController.items.

interface TestItemCollection {
    size: number;
    add(item): void;
    delete(itemId): void;
    forEach(callback, thisArg?): void;
    get(itemId): undefined | TestItem;
    replace(items): void;
}

Hierarchy

  • Iterable<[id: string, testItem: TestItem]>
    • TestItemCollection

Implemented by

Properties

Methods

Properties

size: number

Gets the number of items in the collection.

Methods

  • Iterate over each entry in this collection.

    Parameters

    • callback: ((item, collection) => unknown)

      Function to execute for each entry.

    • Optional thisArg: any

      The this context used when invoking the handler function.

    Returns void

  • Efficiently gets a test item by ID, if it exists, in the children.

    Parameters

    • itemId: string

      Item ID to get.

    Returns undefined | TestItem

    The found item or undefined if it does not exist.