# Install Command

The `redefine install` command is used to install the redefine plugin and enable redefine's functionality. It's important to note that the start command should be executed prior to running the tests.

### **Testing Framework**

The testing framework flag is a required field for successful redefine installation. It specifies the testing framework to be used for test execution.

To see the list of supported testing frameworks, refer to the documentation [supported-technologies](https://docs.redefine.dev/integrations/supported-technologies "mention")

For example, running the following command would make use of the `pytest` testing framework:

```bash
redefine install --pytest --<selection-mode>
```

### Selection Mode

The selection mode flag is a mandatory parameter for the start command. It specifies the relevant selection mode for the test execution.

The available selection modes are:

[`--optimize`](https://docs.redefine.dev/configuration/selection-modes/optimize) , [`--discover`](https://docs.redefine.dev/configuration/selection-modes/discover) , [`--prioritize`](https://docs.redefine.dev/configuration/selection-modes/prioritize) , [`--fail-fast`](https://docs.redefine.dev/configuration/selection-modes/fail-fast) , [`--worker`](https://docs.redefine.dev/parallel-test-execution#workers)

For instance, executing the following command would employ the `discover` mode:

```bash
redefine install --<testing-framework> --discover
```

### Exit code

The `--exit-code` flag enhances error handling during installations by modifying the behavior of the start command to provide clear feedback in the event of issues.

By default, redefine allows pipelines and tests to continue running even in the presence of installation issues. However, this approach can lead to unintended outcomes, such as running all tests in the orchestrator within a remote-workers architecture or executing tests despite not aligning with the user's preferred timeframe.

To use the `--exit-code` flag, include it in the redefine start command as follows:

```bash
redefine install --<testing-framework> --<selection-mode> --exit-code
```

### Remote workers architecture specific flags

Certain flags are specifically relevant to the remote workers' architecture. These flags provide functionality tailored to this architecture.

To learn more about these flags and their usage, refer to the relevant documentation available at [parallel-test-execution](https://docs.redefine.dev/configuration/parallel-test-execution "mention")
