Skip to content

Commit

Permalink
feat: headers method
Browse files Browse the repository at this point in the history
  • Loading branch information
DarronEngelbrecht committed Dec 16, 2024
1 parent a2cad41 commit d191f0f
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions stress-testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,14 @@ $result = stress('example.com/articles')->put(["name" => "Nuno"]);
$result = stress('example.com/articles')->post(["name" => "Nuno"]);
```

If you want to specify request headers, you can use the provided `headers` method.

```php
$result = stress('example.com/articles')->headers([
"Authorization" => "Bearer SecretToken",
])->get()
```

The `stress()` function return the stress test result, which you can use to set expectations. Here is the list of available methods:

<a name="the-stress-function-request-duration"></a>
Expand Down

0 comments on commit d191f0f

Please sign in to comment.