> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# includeTaskLocation

- **Type:** `boolean`
- **Default:** `false`
- **CLI:** `--includeTaskLocation`

Whether to include the location information of tests when collecting test information.

When enabled, this configuration adds line and column number information to test cases and suites. This is useful for debugging and when reporters need to collect test information.

Note that enabling this configuration may slightly decrease test execution performance.


**CLI**

```bash
npx rstest --includeTaskLocation
```


**rstest.config.ts**

```ts
import { defineConfig } from '@rstest/core';

export default defineConfig({
  includeTaskLocation: true,
});
```


## Using with the list command

The `includeTaskLocation` option is particularly useful when used with the `list` command, especially when you want to see the exact location of tests:

```bash
npx rstest list --printLocation
```

This will automatically enable `includeTaskLocation` and display the location information for each test case.

## Example output

With `includeTaskLocation` enabled, reporters and the `list` command will include location information:

```json
{
  "testId": "test-1",
  "name": "should calculate correct sum",
  "testPath": "/path/to/test.spec.ts",
  "location": {
    "line": 15,
    "column": 3
  }
}
```
