> ## Documentation Index > Fetch the complete documentation index at: https://www.canva.dev/docs/apps/llms.txt > Use this file to discover all available pages before exploring further. # initTestEnvironment API reference for the initTestEnvironment method. WARNING: This API is only for use in unit testing and shouldn't be part of your public app. Initializes a test environment for the `@canva/platform` package, enabling unit tests to mock Canva's APIs. This method should only be called once in a test environment, such as in a Jest setup file. ## Returns `void` ## See [https://www.canva.dev/docs/apps/testing/](https://www.canva.dev/docs/apps/testing/)