Skip to content

Conversation

@cyanglaz
Copy link
Contributor

@cyanglaz cyanglaz commented Oct 6, 2023

Fix the typo in didBeginDraggingMarker

The UITest will drag the marker then looking for the text indications that all the dragging callbacks are called, like the screenshot below:

Screenshot 2023-10-06 at 3 36 46 PM

fixes flutter/flutter#135778

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the relevant style guides and ran the auto-formatter. (Unlike the flutter/flutter repo, the flutter/packages repo does use dart format.)
  • I signed the CLA.
  • The title of the PR starts with the name of the package surrounded by square brackets, e.g. [shared_preferences]
  • I listed at least one issue that this PR fixes in the description above.
  • I updated pubspec.yaml with an appropriate new version according to the pub versioning philosophy, or this PR is exempt from version changes.
  • I updated CHANGELOG.md to add a description of the change, following repository CHANGELOG style.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

If you need help, consider asking for advice on the #hackers-new channel on Discord.

fix

revert bundle id

remove test
Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with some minor comments. Thanks for all the new test code here! It's crazy that this works even without the key set up. I guess it does everything but draw?

@@ -1,3 +1,7 @@
## 2.3.2

* Fix an issue where the onDragEnd callback for marker is not called.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Fixes

(Per repo CHANGELOG style guide.)

isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.


#import <XCTest/XCTest.h>

static const CGFloat kWaitTime = 15;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be much longer (maybe 60), since Flutter policy is to not have timeouts in tests, to avoid flake. It's really inconvenient to have no timeouts with the XCUITest APIs, so a very long value is our best option.


#import <XCTest/XCTest.h>

static const CGFloat kWaitTime = 15;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: This should be an NSTimeInterval rather than a CGFloat, since that conveys unit information.

markerPosition = newPosition;
if (!_onDragXcodeUITestHelperText.contains('\n_onMarkerDrag called')) {
// _onMarkerDrag can be called multiple times during a single drag.
// Only log n_onMarkerDrag once per dragging action to reduce noises in UI.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: n_ -> _ (looks like copypasta from the newline probably).

@cyanglaz
Copy link
Contributor Author

cyanglaz commented Oct 7, 2023

I guess it does everything but draw?

Yes it probably does everything but draw. We could possibly add more XCUITests.

isa = XCBuildConfiguration;
buildSettings = {
ASSETCATALOG_COMPILER_GENERATE_SWIFT_ASSET_SYMBOL_EXTENSIONS = YES;
CLANG_ENABLE_MODULES = YES;
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We need this to import the google maps module.

@cyanglaz
Copy link
Contributor Author

cyanglaz commented Oct 7, 2023

Updated the project.pbxproj file, @stuartmorgan Could you please double check to see if I'm missing anything?

(I also added a failure in the UITest to make sure the CI picked up the test and fail, I will revert that change before landing)

Copy link
Collaborator

@stuartmorgan-g stuartmorgan-g left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. There may be a couple more build properties that could be removed, but it's a short enough list at this point that it's fine if it's not absolutely minimal.

@cyanglaz
Copy link
Contributor Author

The test failed so the ci did pick up the test. Reverting the intentional code that made the test fail and landing when green.

@cyanglaz cyanglaz added the autosubmit Merge PR when tree becomes green via auto submit App label Oct 10, 2023
@auto-submit auto-submit bot merged commit 158ec1f into flutter:main Oct 10, 2023
engine-flutter-autoroll added a commit to engine-flutter-autoroll/flutter that referenced this pull request Oct 10, 2023
auto-submit bot pushed a commit to flutter/flutter that referenced this pull request Oct 10, 2023
flutter/packages@7de08ec...4b483f2

2023-10-10 [email protected] Run tests on either macOS 12 or macOS 13 (flutter/packages#5089)
2023-10-10 [email protected] [google_map_flutter_ios] fix `didBeginDraggingMarker` typo (flutter/packages#5085)
2023-10-09 [email protected] [process] Import the `process` package (flutter/packages#5095)
2023-10-09 [email protected] [go_router] Fixes missing state.extra in onException() (flutter/packages#5077)
2023-10-09 49699333+dependabot[bot]@users.noreply.github.com Bump github/codeql-action from 2.22.0 to 2.22.1 (flutter/packages#5094)
2023-10-09 [email protected] Roll Flutter from 5207a30 to f52fe4f (18 revisions) (flutter/packages#5093)
2023-10-09 [email protected] [platform] Example app for platform (flutter/packages#4834)
2023-10-09 49699333+dependabot[bot]@users.noreply.github.com Bump ossf/scorecard-action from 2.2.0 to 2.3.0 (flutter/packages#5091)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
@cyanglaz cyanglaz deleted the google_map_wrong_api branch October 10, 2023 16:17
Mairramer pushed a commit to Mairramer/flutter that referenced this pull request Oct 10, 2023
flutter/packages@7de08ec...4b483f2

2023-10-10 [email protected] Run tests on either macOS 12 or macOS 13 (flutter/packages#5089)
2023-10-10 [email protected] [google_map_flutter_ios] fix `didBeginDraggingMarker` typo (flutter/packages#5085)
2023-10-09 [email protected] [process] Import the `process` package (flutter/packages#5095)
2023-10-09 [email protected] [go_router] Fixes missing state.extra in onException() (flutter/packages#5077)
2023-10-09 49699333+dependabot[bot]@users.noreply.github.com Bump github/codeql-action from 2.22.0 to 2.22.1 (flutter/packages#5094)
2023-10-09 [email protected] Roll Flutter from 5207a30 to f52fe4f (18 revisions) (flutter/packages#5093)
2023-10-09 [email protected] [platform] Example app for platform (flutter/packages#4834)
2023-10-09 49699333+dependabot[bot]@users.noreply.github.com Bump ossf/scorecard-action from 2.2.0 to 2.3.0 (flutter/packages#5091)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages-flutter-autoroll
Please CC [email protected],[email protected] on the revert to ensure that a human
is aware of the problem.

To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App p: google_maps_flutter platform-ios

Projects

None yet

Development

Successfully merging this pull request may close these issues.

onDragStart not firing for Markers for IOS Maps SDK

2 participants