Fix an ErrorProne warning about under-specified equals
Comparing two ImmutableCollections with equals() may fall back to Object.equals, which only checks identity without comparing the contents. Calling asList() avoids this. Currently this is a no-op because the object returned by ImmutableSortedMap.values() is already an ImmutableList.
RELNOTES: None.
@@ -167,7 +167,7 @@ public class BuildConfiguration implements BuildConfigurationApi {
return false;
}
BuildConfiguration otherConfig = (BuildConfiguration) other;
- return fragments.values().equals(otherConfig.fragments.values())
+ return fragments.values().asList().equals(otherConfig.fragments.values().asList())
&& buildOptions.equals(otherConfig.buildOptions);
}
