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

feat(std/testing): Add assertExists assertion #7874

Merged
merged 10 commits into from
Oct 26, 2020

Conversation

getspooky
Copy link
Contributor

No description provided.

std/testing/asserts.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@kitsonk kitsonk left a comment

Choose a reason for hiding this comment

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

I would prefer assertExists().

Prior art: https://www.chaijs.com/api/assert/#method_exists

std/testing/asserts_test.ts Show resolved Hide resolved
@getspooky getspooky changed the title feat(std/testing): Add assertAnything to match anything but null or undefined. feat(std/testing): Add assertExists that the target is neither null nor undefined Oct 11, 2020
@bartlomieju
Copy link
Member

Looks good to me, waiting on @kitsonk's approval

Copy link
Contributor

@kitsonk kitsonk left a comment

Choose a reason for hiding this comment

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

Really want to see full coverage in the tests, as we want to really want to be able to trust that something like an assertion will work as designed.

std/testing/asserts_test.ts Show resolved Hide resolved
std/testing/asserts_test.ts Show resolved Hide resolved
@bartlomieju bartlomieju changed the title feat(std/testing): Add assertExists that the target is neither null nor undefined feat(std/testing): Add assertExists assertion Oct 26, 2020
Copy link
Member

@bartlomieju bartlomieju left a comment

Choose a reason for hiding this comment

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

LGTM, thank you @getspooky!

@bartlomieju bartlomieju merged commit 35caa16 into denoland:master Oct 26, 2020
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 21, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 24, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Jan 31, 2021
caspervonb pushed a commit to caspervonb/deno_std that referenced this pull request Feb 1, 2021
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.

4 participants