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

fixes tests #794

Merged
merged 1 commit into from May 2, 2018
Merged

fixes tests #794

merged 1 commit into from May 2, 2018

Conversation

usmonster
Copy link
Contributor

@usmonster usmonster commented Apr 30, 2018

  • Many tests were not actually invoking assertion functions. Now.they.are()
  • Fixed one test that was then failing because of side-effects from
    previous test setups.
  • Made small changes in some setups to avoid potential false negatives.

(Also: made a tiny unrelated code change to ensure Options always has
boolean properties; does not change any behavior, but may help with
debugging.)

@usmonster usmonster changed the title fix tests fixes tests Apr 30, 2018
index.js Outdated
this.required = ~flags.indexOf('<');
this.optional = ~flags.indexOf('[');
this.required = flags.indexOf('<') >= 0;
this.optional = flags.indexOf('[') >= 0;
this.bool = !~flags.indexOf('-no-');
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you also convert this line as you did with previous one?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I can do it if you want, but it will only be for readability/consistency, as the result is boolean as-is.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yes, for consistency purpose.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

No problem, it's done. :)

- Many tests were not properly invoking assertion functions. Now they
  are.
- Fixed one test then was then failing because of side-effects from
  previous test setups.
- Made small changes in some setups to avoid potential false negatives.

(Also: made a tiny unrelated code change to ensure Options always has
boolean properties; does not change any behavior, but may help with
debugging.)
@roman-vanesyan roman-vanesyan merged commit dcddf69 into tj:master May 2, 2018
@roman-vanesyan
Copy link
Collaborator

Thanks

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.

None yet

3 participants