sininen
sininen

Reputation: 563

Protractor test suite run all tests that are not in a folder

It is possible to create a test suite in Protractor by adding the following to a config file:

suites: {
    test1: "folder1/**/*.spec.js",
    test2: "folder2/**/*.spec.js"
}

Where the test suite test1 will run all tests that are inside folder1.

How can I create a test suite that will run all tests that are not inside the folder folder1?

Upvotes: 1

Views: 286

Answers (1)

sheilak
sheilak

Reputation: 5873

You can run all tests that are not inside folder1 like this:

suites: {
    test: '!(folder1)/**/*.spec.js'
}

Protractor uses Glob to match files from your specified specs or suites in config file.

Upvotes: 4

Related Questions