Skip to content
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

fix failing test by defaulting to empty array #2353

Merged
merged 3 commits into from
Feb 16, 2020

Conversation

JoviDeCroock
Copy link
Member

No description provided.

@github-actions
Copy link

github-actions bot commented Feb 16, 2020

Size Change: +30 B (0%)

Total Size: 38.5 kB

Filename Size Change
dist/preact.js 3.74 kB +7 B (0%)
dist/preact.min.js 3.74 kB +7 B (0%)
dist/preact.module.js 3.76 kB +6 B (0%)
dist/preact.umd.js 3.8 kB +10 B (0%)
ℹ️ View Unchanged
Filename Size Change
compat/dist/compat.js 3 kB 0 B
compat/dist/compat.module.js 3.03 kB 0 B
compat/dist/compat.umd.js 3.05 kB 0 B
debug/dist/debug.js 3.08 kB 0 B
debug/dist/debug.module.js 3.07 kB 0 B
debug/dist/debug.umd.js 3.15 kB 0 B
devtools/dist/devtools.js 175 B 0 B
devtools/dist/devtools.module.js 185 B 0 B
devtools/dist/devtools.umd.js 252 B 0 B
hooks/dist/hooks.js 1.05 kB 0 B
hooks/dist/hooks.module.js 1.08 kB 0 B
hooks/dist/hooks.umd.js 1.13 kB 0 B
test-utils/dist/testUtils.js 390 B 0 B
test-utils/dist/testUtils.module.js 392 B 0 B
test-utils/dist/testUtils.umd.js 469 B 0 B

compressed-size-action

@coveralls
Copy link

coveralls commented Feb 16, 2020

Coverage Status

Coverage remained the same at 99.792% when pulling 1e8cbed on fix-test into e8a6b6d on fix/null-placeholder-sibling-placement.

@andrewiggins
Copy link
Member

Just realized I messed up one of the tests in my branch. Rebase on top to see if everything still passes

@JoviDeCroock
Copy link
Member Author

@andrewiggins I found another fix which works on the rebased branch

? tmp.props.children
: Array.isArray(tmp)
? tmp
: [tmp];
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There are scenario's where we skip an update with a placeholder, in this case tmp returns null with render, this is not an array so we [null] it

@JoviDeCroock JoviDeCroock merged commit 40b672a into fix/null-placeholder-sibling-placement Feb 16, 2020
@JoviDeCroock JoviDeCroock deleted the fix-test branch February 16, 2020 14:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants