Skip to content

Fix issues with Auth integration tests#1851

Open
a-maurice wants to merge 5 commits intomainfrom
am-auth_tests
Open

Fix issues with Auth integration tests#1851
a-maurice wants to merge 5 commits intomainfrom
am-auth_tests

Conversation

@a-maurice
Copy link
Copy Markdown
Contributor

Description

Provide details of the change, and generalize the change in the PR title above.

There are two noticeable issues in the nightly tests:
SignInWithBadEmail would regularly fail because the backend thought it was suspicious, which resulted in the wrong error. Just deleting that test, since that behavior doesn't really need to be tested anyway.
LinkAnonymousUserWithEmailCredential was not properly cleaning up the users it created, resulting in leftover users on the backend that needed to be cleaned up. Refactored the test to address it.

Also adjusted the generated emails, so that they can be more easily tracked back if they are not cleaned up properly.


Testing

Describe how you've tested these changes. Link any manually triggered Integration tests or CPP binary SDK Packaging Github Action workflows, if applicable.

https://github.com/firebase/firebase-cpp-sdk/actions/runs/25352154658


Type of Change

Place an x the applicable box:

  • Bug fix. Add the issue # below if applicable.
  • New feature. A non-breaking change which adds functionality.
  • Other, such as a build process or documentation change.

Notes

  • Bug fixes and feature changes require an update to the Release Notes section of release_build_files/readme.md.
  • Read the contribution guidelines CONTRIBUTING.md.
  • Changes to the public API require an internal API review. If you'd like to help us make Firebase APIs better, please propose your change in a feature request so that we can discuss it together.

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the Firebase Auth integration tests by updating the GenerateEmailAddress utility to incorporate platform-specific labels and test names, which improves the traceability of generated test accounts. It also refactors several test cases for better robustness, including more explicit error checking for provider linking and additional debug logging. The review feedback suggests using std::to_string for more idiomatic and portable integer-to-string conversion and simplifying the email string construction logic.

Comment thread auth/integration_test/src/integration_test.cc Outdated
Comment thread auth/integration_test/src/integration_test.cc Outdated
@a-maurice a-maurice added the skip-release-notes Skip release notes check label May 5, 2026
@a-maurice
Copy link
Copy Markdown
Contributor Author

/gemini review

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the Firebase Auth integration tests by improving the GenerateEmailAddress utility to include platform-specific identifiers and sanitized test names, while also ensuring all generated emails are lowercase. Additionally, it introduces platform name macros, adds debug logging for failed user deletions, refactors the anonymous user linking test for better error verification, and removes a redundant test case. There are no review comments to provide feedback on.

@a-maurice a-maurice requested a review from AustinBenoit May 5, 2026 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip-release-notes Skip release notes check

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant