-
Notifications
You must be signed in to change notification settings - Fork 46.6k
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
[attribute-behavior] Snapshot test #10587
Conversation
82112f5
to
de3eb2e
Compare
If we're not ready to check in the actual snapshot file yet, because we aren't happy with the output, I would prefer to check in the rest of the changes in this PR (like extracting the config into a separate module) so I don't have to keep rebasing whenever we change the table. |
Ah, this is super cool. I was wondering if we'd ever do headless testing of this stuff. |
@nhunzaker Do you want to help out reviewing this PR? |
Same data as the attribute table, but in the form of a snapshot. Uses puppeteer to run headless Chromium.
de3eb2e
to
4744ca9
Compare
Rebased |
return; | ||
} | ||
|
||
if (!didStartTest && str.includes('http://localhost:9292/')) { |
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's probably a better way to do this but idk what it is :D
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.
What I really want is a callback that says "Hey CRA is serving your app now, go ahead and run your tests."
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.
I'd vote do a production build and run at as a static for serve, if possible.
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.
- that way you have direct control of setup and teardown without any ipc
How does this work? Does it build the bundles first? |
Nah, just runs CRA dev server. But you're right, would probably be easier to just build the bundle and then serve a static file. I think maybe puppeteer lets you give it a file. |
The thing that bothers me is that this doesn't solve the warning deduplication problem (afaik). I always edit the bundle to remove |
I see. Could we add a secret feature flag? |
¯\(ツ)/¯ |
Superseded by #10595. |
Same data as the attribute table, but in the form of a snapshot. Uses puppeteer to run headless Chromium.