The Database emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIREBASE_DATABASE_EMULATOR_HOST.
The Firestore emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIRESTORE_EMULATOR_HOST.
The Firebase Emulator hub. Can also be specified via the environment variable FIREBASE_EMULATOR_HUB. If specified either way, other running emulators can be automatically discovered, and thus do not to be explicity specified.
The project ID of the test environment. Can also be specified via the environment variable GCLOUD_PROJECT.A "demo-*" project ID is strongly recommended, especially for unit testing. See: https://firebase.google.com/docs/emulator-suite/connect_firestore#choose_a_firebase_project
The Storage emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIREBASE_STORAGE_EMULATOR_HOST.
TestEnvironmentConfig.database
The Database emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIREBASE_DATABASE_EMULATOR_HOST.
Signature:
database?:EmulatorConfig;
TestEnvironmentConfig.firestore
The Firestore emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIRESTORE_EMULATOR_HOST.
Signature:
firestore?:EmulatorConfig;
TestEnvironmentConfig.hub
The Firebase Emulator hub. Can also be specified via the environment variable FIREBASE_EMULATOR_HUB. If specified either way, other running emulators can be automatically discovered, and thus do not to be explicity specified.
Signature:
hub?:HostAndPort;
TestEnvironmentConfig.projectId
The project ID of the test environment. Can also be specified via the environment variable GCLOUD_PROJECT.
A "demo-*" project ID is strongly recommended, especially for unit testing. See: https://firebase.google.com/docs/emulator-suite/connect_firestore#choose_a_firebase_project
Signature:
projectId?:string;
TestEnvironmentConfig.storage
The Storage emulator. Its host and port can also be discovered automatically through the hub (see field "hub") or specified via the environment variable FIREBASE_STORAGE_EMULATOR_HOST.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-28 UTC."],[],[],null,["Configuration of the unit testing environment, including emulators.\n\n\u003cbr /\u003e\n\n**Signature:** \n\n export interface TestEnvironmentConfig \n\nProperties\n\n| Property | Type | Description |\n|-------------------------------------------------------------------------------------------|--------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [database](./rules-unit-testing.testenvironmentconfig.md#testenvironmentconfigdatabase) | [EmulatorConfig](./rules-unit-testing.md#emulatorconfig) | The Database emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIREBASE_DATABASE_EMULATOR_HOST. |\n| [firestore](./rules-unit-testing.testenvironmentconfig.md#testenvironmentconfigfirestore) | [EmulatorConfig](./rules-unit-testing.md#emulatorconfig) | The Firestore emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIRESTORE_EMULATOR_HOST. |\n| [hub](./rules-unit-testing.testenvironmentconfig.md#testenvironmentconfighub) | [HostAndPort](./rules-unit-testing.hostandport.md#hostandport_interface) | The Firebase Emulator hub. Can also be specified via the environment variable FIREBASE_EMULATOR_HUB. If specified either way, other running emulators can be automatically discovered, and thus do not to be explicity specified. |\n| [projectId](./rules-unit-testing.testenvironmentconfig.md#testenvironmentconfigprojectid) | string | The project ID of the test environment. Can also be specified via the environment variable GCLOUD_PROJECT.A \"demo-\\*\" project ID is strongly recommended, especially for unit testing. See: https://firebase.google.com/docs/emulator-suite/connect_firestore#choose_a_firebase_project |\n| [storage](./rules-unit-testing.testenvironmentconfig.md#testenvironmentconfigstorage) | [EmulatorConfig](./rules-unit-testing.md#emulatorconfig) | The Storage emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIREBASE_STORAGE_EMULATOR_HOST. |\n\nTestEnvironmentConfig.database\n\nThe Database emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIREBASE_DATABASE_EMULATOR_HOST.\n\n**Signature:** \n\n database?: EmulatorConfig;\n\nTestEnvironmentConfig.firestore\n\nThe Firestore emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIRESTORE_EMULATOR_HOST.\n\n**Signature:** \n\n firestore?: EmulatorConfig;\n\nTestEnvironmentConfig.hub\n\nThe Firebase Emulator hub. Can also be specified via the environment variable FIREBASE_EMULATOR_HUB. If specified either way, other running emulators can be automatically discovered, and thus do not to be explicity specified.\n\n**Signature:** \n\n hub?: HostAndPort;\n\nTestEnvironmentConfig.projectId\n\nThe project ID of the test environment. Can also be specified via the environment variable GCLOUD_PROJECT.\n\nA \"demo-\\*\" project ID is strongly recommended, especially for unit testing. See: https://firebase.google.com/docs/emulator-suite/connect_firestore#choose_a_firebase_project\n\n**Signature:** \n\n projectId?: string;\n\nTestEnvironmentConfig.storage\n\nThe Storage emulator. Its host and port can also be discovered automatically through the hub (see field \"hub\") or specified via the environment variable FIREBASE_STORAGE_EMULATOR_HOST.\n\n**Signature:** \n\n storage?: EmulatorConfig;"]]