Skip to content

Commit

Permalink
Document Spectator::reset
Browse files Browse the repository at this point in the history
  • Loading branch information
bastien-phi committed Mar 15, 2024
1 parent 202a270 commit cba7a21
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -317,6 +317,33 @@ class ExampleTestCase
}
```

### Deactivating Spectator

If you want to deactivate Spectator for a specific test, you can use the `Spectator::reset` method:

```php
<?php

use Spectator\Spectator;

class ExampleTest extends TestCase
{
public function setUp(): void
{
parent::setUp();

Spectator::using('Api.v1.json');
}

public function testWithoutSpectator()
{
Spectator::reset();

// Run your test without Spectator
}
}
```

## Core Concepts

### Approach
Expand Down

0 comments on commit cba7a21

Please sign in to comment.