Skip to content

Conversation

@greenjoe
Copy link
Contributor

The inspection description now says which types cannot be compared so that it's easier to find an error, especially when comparing two types with same name but different packages.
ScalaInspectionTestBase methods that check if there are errors are slightly changed so that it is possible to test for inspections with non-constant description.

It looks like in some cases from tests the type description looks a bit strange (B.type when B is an object or a.type when comparing with isInstanceOf) but I believe it is still much better than not having types in descriptions at all.

The message now says which types cannot be compared so that
it's easier to find an error.
ScalaInspectionTestBase methods that check if there are errors
are slightly changed so that it is possible to test for errors with
non-constant description.
@niktrop
Copy link
Contributor

niktrop commented Apr 11, 2017

I merged your fix manually with a couple of changes: 7f9428b
I have added extracting singleton types to the generateComparingUnrelatedTypesMsg method and a test for the case when types have the same simple name.
Very nice fix, thank you.

@niktrop niktrop closed this Apr 11, 2017
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.

2 participants