Migrate FaceBookLoginTest to Playwright TypeScript - #16
Open
devin-ai-integration[bot] wants to merge 1 commit into
Open
Migrate FaceBookLoginTest to Playwright TypeScript#16devin-ai-integration[bot] wants to merge 1 commit into
devin-ai-integration[bot] wants to merge 1 commit into
Conversation
Author
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Ports the single legacy Selenium/TestNG class
FaceBookLoginTest(plus its page object) to a self-contained Playwright TypeScript project undere2e-playwright/(ownpackage.json,playwright.config.ts, chromium-only). No Java sources,pom.xml, or TestNG suites are touched — the legacy suite still runs and still fails as designed.Locator change that matters: the legacy page object used
@FindBy(id = "email"), but current facebook.com renders generated ids (id="_R_1h6kqsqppb6amH1_"), so the fields are addressed by their stablenameattributes:Honest handling of the legacy assertion: the Java test ends in
Assert.assertTrue(false, "Login failed : Test failed")— an unconditional failure, not a statement about the app, and there are no credentials in the repo to actually authenticate with. Rather than rewriting it into something that passes vacuously, the spec splits the intent:The passing test asserts only what it can honestly observe: the login form is visible, both fields hold the values entered ("abc"/"abc", as in the legacy test), and after submit the browser is still on a facebook.com host. Local run: 1 passed, 1 skipped (the
fixme).CI:
.github/workflows/playwright-facebook.ymlrunsnpx playwright test tests/facebook-login.spec.tsonpull_request(paths-filtered toe2e-playwright/**and the workflow itself) and uploads the HTML report. Note the spec hits the live facebook.com, so it depends on that being reachable from the runner.Link to Devin session: https://partner-workshops.devinenterprise.com/sessions/f6ec885af4f742e5b9c75c712adfb436
Link to Devin session: https://partner-workshops.devinenterprise.com/sessions/f46eebc578904c8fbce42f04bb0b1898
Requested by: @sumitshatwara