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

assertTrue/assertFalse does not fail #6

Closed
genius257 opened this issue Sep 15, 2020 · 0 comments
Closed

assertTrue/assertFalse does not fail #6

genius257 opened this issue Sep 15, 2020 · 0 comments
Labels
bug Something isn't working

Comments

@genius257
Copy link
Owner

assertTrue(False)
assertTrue(Null)
assertTrue("WRONG")
;No errors

This is caused because a mix of:

some matches methods (like Au3UnitConstraintIsTrue_Matches) returning a boolean instead of an Au3UnitExpectationFailedException

And:

If $returnResult Then Return ($comparisonFailure = Null) ? $success : SetError(1, 0, $matches)

Suggested fix:

If (IsBool($matches) And $matches) Or (Not IsBool($matches)) And $comparisonFailure = Null Then $success = True
@genius257 genius257 added the bug Something isn't working label Sep 15, 2020
genius257 added a commit that referenced this issue Sep 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant