-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Rewrite some tests to no longer rely on internals #2132
Conversation
@@ -1809,24 +1795,6 @@ describe('Components', () => { | |||
expect(child._vnode._dom).to.equalNode(child.base); | |||
}); | |||
|
|||
it('should update old dom on forceUpdate in a lifecycle', () => { |
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 just moved this test into the forceUpdate
describe section below.
} from '../_util/helpers'; | ||
import { div, span, p } from '../_util/dom'; | ||
|
||
/** @jsx createElement */ | ||
const h = createElement; | ||
|
||
let spyAll = obj => Object.keys(obj).forEach(key => sinon.spy(obj, key)); |
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.
Removed this copy of the spyAll
function and replaced it with the same function declared in helpers.js
. Same for sortAttributes
below
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.
👍 really love this :)
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.
Top notch as usual 🙌💯
This is a stepping stone to allowing us to run tests against minified builds