-
-
Notifications
You must be signed in to change notification settings - Fork 257
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
Implement testing RFC #1211
Implement testing RFC #1211
Conversation
let renderSettled: () => Promise<void>; | ||
|
||
// TODO need to add the actual version `@ember/renderer` landed once we know it | ||
if (macroCondition(dependencySatisfies('ember-source', '>=4.9999999.0'))) { |
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.
Ok, now that the Ember change has landed for realz let's update this to 4.5.0-beta.1.
Co-authored-by: Robert Jackson <me@rwjblue.com>
Co-authored-by: Robert Jackson <me@rwjblue.com>
9ccfdf6
to
8d935fb
Compare
11eeb34
to
a749f81
Compare
d41647a
to
2c6b47f
Compare
addon-test-support/@ember/test-helpers/-internal/is-component.ts
Outdated
Show resolved
Hide resolved
|
||
const OUTLET_TEMPLATE = hbs`{{outlet}}`; | ||
const EMPTY_TEMPLATE = hbs``; | ||
const INVOKE_PROVIDED_COMPONENT = hbs`<this.ProvidedComponent />`; |
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.
@chriskrycho here is this mystic this.ProvidedComponent
that fails ember-optimized scenario
PR emberjs/ember-test-helpers#1211 (released in v2.8.0) made `ember-source` a peerDependency of `@ember/test-helpers`. In case of `ember-keyboard` monorepo setup, package `ember-source` does not get hoisted and stay in the `test-app/node_modules` but at the same time `@ember/test-helpers` gets hoisted as well as some another version of `ember-source`. By not hoisting `@ember/test-helpers` in the `test-app` package we avoid this issue.
This PR implements the majority of emberjs/rfcs#785. More specifically, it adds:
rerender
helper that allows tests to wait exclusively on render operations (as opposed to full settledness).render
that accepts components as well as templatesNotably, this PR does not address the component named argument ergonomics issue mentioned in the RFC. That will need to come in a follow-on RFC/PR.
TODO
renderSettled
via renderer package ember.js#20053 for therenderSettled
APIrenderSettled
is actually landed and shipped, we'll need to update therenderSettled
ponyfill that lives inember-test-helpers
to actually use the correct Ember version.