mapbox-maps-android icon indicating copy to clipboard operation
mapbox-maps-android copied to clipboard

MAPSAND-379 Style getter extension functions do not save property values

Open paulrenn67 opened this issue 3 years ago • 2 comments

Summary of changes

This branch adds support to preserve cached layer properties during the getLayer call.

We then use any cached properties when the layer is later added to the style.

See related PR in mapbox-maps-android-internal which update the tests in this PR.

User impact (optional)

Should not be any.

Pull request checklist:

  • [x] Briefly describe the changes in this PR.
  • [ ] Include before/after visuals or gifs if this PR includes visual changes.
  • [x] Write tests for all new functionality. If tests were not written, please explain why.
  • [ ] Optimize code for java consumption (@JvmOverloads, @file:JvmName, etc).
  • [ ] Add example if relevant.
  • [ ] Document any changes to public APIs.
  • [ ] Run make update-api to update generated api files, if there's public API changes, otherwise the verify-api-* CI steps might fail.
  • [x] Update CHANGELOG.md or use the label 'skip changelog', otherwise check changelog CI step will fail.
  • [ ] If this PR is a v10.[version] release branch fix / enhancement, merge it to main firstly and then port to v10.[version] release branch.

Fixes: https://mapbox.atlassian.net/browse/MAPSAND-379

PRs must be submitted under the terms of our Contributor License Agreement CLA.

paulrenn67 avatar Aug 24 '22 06:08 paulrenn67

@paulrenn67 I added bug label - verify-code will not pass then until you add the changelog entry. However in your case it's failing because of ktlint as well. Could you please fix that so that CI will start?

kiryldz avatar Aug 24 '22 07:08 kiryldz

Unit tests are failing with ClassCastExceptions...

kiryldz avatar Aug 24 '22 11:08 kiryldz