Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integration Test Failure Caused by Database Rules #48

Closed
hiranya911 opened this issue Jun 30, 2017 · 1 comment
Closed

Integration Test Failure Caused by Database Rules #48

hiranya911 opened this issue Jun 30, 2017 · 1 comment
Assignees

Comments

@hiranya911
Copy link
Contributor

Integration test suite may sometimes fail with the following error:

FIREBASE WARNING: set at /blocked failed: permission_denied 
[FAILURE] nonNullApp.database().ref("blocked").set(): Error: PERMISSION_DENIED: Permission denied

This happens when there are custom rules in the realtime database. Changing the rules back to defaults usually fixes the issue:

{
  "rules": {
    ".read": "auth != null",
    ".write": "auth != null",
  }
}

The integration test suite should not depend on a specific rules configuration. If such a dependency is needed, the test suite should update the rules config during the setup phase (Java and Python SDKs do this already).

@hiranya911
Copy link
Contributor Author

This has been implemented. Integration tests overwrite the database rules with the defaults now. If this is deemed too invasive, we can implement a warning+prompt mechanism in the future.

@hiranya911 hiranya911 self-assigned this Jul 10, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant