-
Notifications
You must be signed in to change notification settings - Fork 13
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
Add new DNS Record form tests #313
Add new DNS Record form tests #313
Conversation
Hmmm, not quite sure why tests only fail on |
CI issue with Mobile Safari seems to be related to this open issue in playwright. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great to see. cc @Myrfion for another reviewer, since he wrote this.
Should we add tests for validation errors on required fields? For example, if we put an IP address for a CNAME? Could do that in follow-ups too.
test('does not create dns record if required fields are empty', async ({ page }) => { | ||
await page.goto('/domains/new'); | ||
await page.getByRole('button', { name: 'Create' }).click(); | ||
await expect(page).toHaveURL(/.*domains\/new/); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we want to check for an error message in the page?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In a follow-up, we could style the control and check for that I guess.
Hmm, I don't those validations exist yet. I think those can be added after #277 or as part of it |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome
Resolves #278, resolves #296
Since writing the tests relied on setting up the shared auth session, these have been combined into one PR. The following changes have been made:
.gitignore
. This file is generated before the tests are run so it is not necessary to save itSteps to test
You can check the CI to confirm that the tests pass. Alternatively,
npm run docker
npm run build
npm run test:e2e:run