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

Warning on use of operator === #127

Closed
evnu opened this issue Oct 28, 2019 · 1 comment
Closed

Warning on use of operator === #127

evnu opened this issue Oct 28, 2019 · 1 comment

Comments

@evnu
Copy link
Collaborator

evnu commented Oct 28, 2019

Since 1.2.0, properties seem to result in a warning message use of operator === has no effect. Example module:

defmodule PropcheckMultipleExprWarningTest do
  use ExUnit.Case
  use PropCheck

  property "A Property" do
    forall x <- nat() do
      x >= 0
    end
  end
end
$ mix test
...
warning: use of operator === has no effect
  test/propcheck_multiple_expr_warning_test.exs:6

warning: use of operator === has no effect
  test/propcheck_multiple_expr_warning_test.exs:10

I believe this is caused by #118. The warning is present in this Travis job (
93426c6, commit from that PR), but it is not present in this Travis job (d1dc288, a commit shortly before that PR was merged).

@evnu
Copy link
Collaborator Author

evnu commented Oct 28, 2019

I think this has been fixed "accidentally" with #126, specifically with c60f7a8. With the current master, I cannot reproduce the warnings from the example above anymore.

Interestingly, the warning was caused by this line in propcheck.ex (introduced in 9c1e9c3, part of #118):

env_verbose? = System.get_env("PROPCHECK_VERBOSE") == "1"

If I set env_verbose? to true on 161da5c (the commit prior to c60f7a8), the warning is gone. I cannot explain this warning, but at least it is gone now.

@evnu evnu closed this as completed Oct 28, 2019
@evnu evnu changed the title Warning on use of operator Warning on use of operator === Oct 28, 2019
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

No branches or pull requests

1 participant