Skip to content

Commit d0fed0b

Browse files
committed
docs(vitest-integrations): fix subheadings
1 parent f76386f commit d0fed0b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/content/docs/workers/testing/vitest-integration/known-issues.mdx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ Using WebSockets with Durable Objects with the [`isolatedStorage`](/workers/test
3434

3535
When the `isolatedStorage` flag is enabled (the default), the test runner will undo any writes to the storage at the end of the test as detailed in the [isolation and concurrency documentation](/workers/testing/vitest-integration/isolation-and-concurrency/). However, Cloudflare recommends that you consider the following actions to avoid any common issues:
3636

37-
## Await all storage operations
37+
#### Await all storage operations
3838

3939
Always `await` all `Promise`s that read or write to storage services.
4040

@@ -46,15 +46,15 @@ beforeAll(async () => {
4646
});
4747
```
4848

49-
## Explicitly signal resource disposal
49+
#### Explicitly signal resource disposal
5050

5151
When calling RPC methods of a Service Worker or Durable Object that return non-primitive values (such as objects or classes extending `RpcTarget`), use the `using` keyword to explicitly signal when resources can be disposed of. See [this example test](https://github.com/cloudflare/workers-sdk/tree/main/fixtures/vitest-pool-workers-examples/rpc/test/unit.test.ts#L155) and refer to [explicit-resource-management](/workers/runtime-apis/rpc/lifecycle#explicit-resource-management) for more details.
5252

5353
```ts
5454
using result = await stub.getCounter();
5555
```
5656

57-
## Consume response bodies
57+
#### Consume response bodies
5858

5959
When making requests via `fetch` or `R2.get()`, consume the entire response body, even if you are not asserting its content. For example:
6060

0 commit comments

Comments
 (0)