-
Notifications
You must be signed in to change notification settings - Fork 0
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
Scraper tests #111
Scraper tests #111
Conversation
https://www.scrapingbee.com/webscraping-questions/playwright/how-to-load-local-files-in-playwright/ this might be a way of testing the scraping in Playwright, with jest, but it is currently extremely slow and it impedes testing.. |
Current bug with Jest, and workaround here: |
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.
- Write test for a successful POST
- Replace custom Prisma queries with existing methods, for example:
const insertResult = await insertPaper(myPaper);
const getResult = await getPaper(myPaper.id);
expect(insertResult.title).toEqual(getResult.title);
Instead of:
let testRes: Paper | null = await prisma.paper.findFirst({
where: {
source: 'acm',
},
});
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.
Writing scraper tests for the Playwright paper scraping feature.