E2E Integration Tests #89
Replies: 3 comments 9 replies
-
What's the advantage of Cypress over Selenium? I ask because the comparisons I found seemed to give the edge to Cypress in speed, but that's because it doesn't use browser drivers. Wouldn't the browser driver approach make the tests more useful and granular? I.e., we could notice if something is working for all browsers except Safari and change things appropriately. |
Beta Was this translation helpful? Give feedback.
-
Based on our requirements, browser support and ease of CI/CD integration, I'm currently inclined to go with Playwright, although we'd have to integrate it and test it's viability. @kgodey @mathemancer Please let me know what you think. |
Beta Was this translation helpful? Give feedback.
-
I can 👍 the sentiment from that Hacker News thread about Cypress. It's very powerful, and the GUI when testing locally is really, really nice. The test output is very legible, and I really want to like it...but, the API for writing tests is definitely a little frustrating. Something like Playwright (which is basically just cross-browser Puppeteer) is great, and now has a built-in test runner that makes it even easier to work with. https://playwright.dev/docs/test-runners Example playwright test: import { test, expect } from '@playwright/test';
test('basic test', async ({ page }) => {
await page.goto('https://playwright.dev/');
const name = await page.innerText('.navbar__title');
expect(name).toBe('Playwright');
}); |
Beta Was this translation helpful? Give feedback.
-
Currently we have the setup for unit tests in backend and frontend.
This thread is to decide upon End-to-end integration tests and when to proceed with it (currently, at the date of start of this discussion, it is too early to set up).
My recommendation is to use Cypress, and create test cases mimicking user behaviour.
We can brainstorm other options/thoughts around this.
Beta Was this translation helpful? Give feedback.
All reactions