Skip to content

Commit

Permalink
Docs: Databases not on ".firebaseio.com"
Browse files Browse the repository at this point in the history
Early in the development of Firebase, all databases were accessible at the URL: 
    https://<projectId>.firebaseio.com

However, now there are multiple locations and instances of databases, and that assumption no longer holds. 
If your database is not at `https://<projectId>.firebaseio.com`, cypress-firebase will seem to hang, rather than giving an explicit error.
For that reason it is very helpful to warn people up front, to put in the URL.
  • Loading branch information
darrelfrancis authored Mar 19, 2023
1 parent 3aaa8a7 commit b467044
Showing 1 changed file with 14 additions and 6 deletions.
20 changes: 14 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,13 @@ If you are interested in what drove the need for this checkout [the why section]
// NOTE: Add "supportFile" setting if separate location is used
setupNodeEvents(on, config) {
// e2e testing node events setup code
return cypressFirebasePlugin(on, config, admin);
// NOTE: If not setting GCLOUD_PROJECT env variable, project can be set like so:
// return cypressFirebasePlugin(on, config, admin, { projectId: 'some-project' });
return cypressFirebasePlugin(on, config, admin,{
// Here is where you can pass special options.
// If you have not set the GCLOUD_PROJECT environment variable, give the projectId here, like so:
// projectId: 'some-project',
// if your databaseURL is not just your projectId plus ".firebaseio.com", then you _must_ give it here, like so:
// databaseURL: 'some-project-default-rtdb.europe-west1.firebasedatabase.app',
});
},
},
});
Expand All @@ -70,9 +74,13 @@ If you are interested in what drove the need for this checkout [the why section]
// NOTE: Make supportFile exists if separate location is provided
setupNodeEvents(on, config) {
// e2e testing node events setup code
return cypressFirebasePlugin(on, config, admin);
// NOTE: If not setting GCLOUD_PROJECT env variable, project can be set like so:
// return cypressFirebasePlugin(on, config, admin, { projectId: 'some-project' });
return cypressFirebasePlugin(on, config, admin,{
// Here is where you can pass special options.
// If you have not set the GCLOUD_PROJECT environment variable, give the projectId here, like so:
// projectId: 'some-project',
// if your databaseURL is not just your projectId plus ".firebaseio.com", then you _must_ give it here, like so:
// databaseURL: 'some-project-default-rtdb.europe-west1.firebasedatabase.app',
});
},
},
});
Expand Down

0 comments on commit b467044

Please sign in to comment.