[google_maps_flutter] Add Marker drag events (#2838)

diff --git a/packages/google_maps_flutter/google_maps_flutter/CHANGELOG.md b/packages/google_maps_flutter/google_maps_flutter/CHANGELOG.md
index 5406dc5..0c95abd 100644
--- a/packages/google_maps_flutter/google_maps_flutter/CHANGELOG.md
+++ b/packages/google_maps_flutter/google_maps_flutter/CHANGELOG.md
@@ -1,3 +1,7 @@
+## 2.0.11
+
+* Add additional marker drag events.
+
 ## 2.0.10
 
 * Update minimum Flutter SDK to 2.5 and iOS deployment target to 9.0.
diff --git a/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/GoogleMapController.java b/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/GoogleMapController.java
index 056e106..9b88103 100644
--- a/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/GoogleMapController.java
+++ b/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/GoogleMapController.java
@@ -467,10 +467,14 @@
   }
 
   @Override
-  public void onMarkerDragStart(Marker marker) {}
+  public void onMarkerDragStart(Marker marker) {
+    markersController.onMarkerDragStart(marker.getId(), marker.getPosition());
+  }
 
   @Override
-  public void onMarkerDrag(Marker marker) {}
+  public void onMarkerDrag(Marker marker) {
+    markersController.onMarkerDrag(marker.getId(), marker.getPosition());
+  }
 
   @Override
   public void onMarkerDragEnd(Marker marker) {
diff --git a/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/MarkersController.java b/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/MarkersController.java
index 189cba0..47ffe9b 100644
--- a/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/MarkersController.java
+++ b/packages/google_maps_flutter/google_maps_flutter/android/src/main/java/io/flutter/plugins/googlemaps/MarkersController.java
@@ -105,6 +105,28 @@
     return false;
   }
 
+  void onMarkerDragStart(String googleMarkerId, LatLng latLng) {
+    String markerId = googleMapsMarkerIdToDartMarkerId.get(googleMarkerId);
+    if (markerId == null) {
+      return;
+    }
+    final Map<String, Object> data = new HashMap<>();
+    data.put("markerId", markerId);
+    data.put("position", Convert.latLngToJson(latLng));
+    methodChannel.invokeMethod("marker#onDragStart", data);
+  }
+
+  void onMarkerDrag(String googleMarkerId, LatLng latLng) {
+    String markerId = googleMapsMarkerIdToDartMarkerId.get(googleMarkerId);
+    if (markerId == null) {
+      return;
+    }
+    final Map<String, Object> data = new HashMap<>();
+    data.put("markerId", markerId);
+    data.put("position", Convert.latLngToJson(latLng));
+    methodChannel.invokeMethod("marker#onDrag", data);
+  }
+
   void onMarkerDragEnd(String googleMarkerId, LatLng latLng) {
     String markerId = googleMapsMarkerIdToDartMarkerId.get(googleMarkerId);
     if (markerId == null) {
diff --git a/packages/google_maps_flutter/google_maps_flutter/android/src/test/java/io/flutter/plugins/googlemaps/MarkersControllerTest.java b/packages/google_maps_flutter/google_maps_flutter/android/src/test/java/io/flutter/plugins/googlemaps/MarkersControllerTest.java
new file mode 100644
index 0000000..afe91d7
--- /dev/null
+++ b/packages/google_maps_flutter/google_maps_flutter/android/src/test/java/io/flutter/plugins/googlemaps/MarkersControllerTest.java
@@ -0,0 +1,131 @@
+// Copyright 2013 The Flutter Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+package io.flutter.plugins.googlemaps;
+
+import static org.mockito.ArgumentMatchers.any;
+import static org.mockito.Mockito.mock;
+import static org.mockito.Mockito.spy;
+import static org.mockito.Mockito.when;
+
+import com.google.android.gms.internal.maps.zzt;
+import com.google.android.gms.maps.GoogleMap;
+import com.google.android.gms.maps.model.LatLng;
+import com.google.android.gms.maps.model.Marker;
+import com.google.android.gms.maps.model.MarkerOptions;
+import io.flutter.plugin.common.BinaryMessenger;
+import io.flutter.plugin.common.MethodChannel;
+import io.flutter.plugin.common.MethodCodec;
+import java.util.ArrayList;
+import java.util.Arrays;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
+import org.junit.Test;
+import org.mockito.Mockito;
+
+public class MarkersControllerTest {
+
+  @Test
+  public void controller_OnMarkerDragStart() {
+    final MethodChannel methodChannel =
+        spy(new MethodChannel(mock(BinaryMessenger.class), "no-name", mock(MethodCodec.class)));
+    final MarkersController controller = new MarkersController(methodChannel);
+    final GoogleMap googleMap = mock(GoogleMap.class);
+    controller.setGoogleMap(googleMap);
+
+    final zzt z = mock(zzt.class);
+    final Marker marker = new Marker(z);
+
+    final String googleMarkerId = "abc123";
+
+    when(marker.getId()).thenReturn(googleMarkerId);
+    when(googleMap.addMarker(any(MarkerOptions.class))).thenReturn(marker);
+
+    final LatLng latLng = new LatLng(1.1, 2.2);
+    final Map<String, String> markerOptions = new HashMap();
+    markerOptions.put("markerId", googleMarkerId);
+
+    final List<Object> markers = Arrays.<Object>asList(markerOptions);
+    controller.addMarkers(markers);
+    controller.onMarkerDragStart(googleMarkerId, latLng);
+
+    final List<Double> points = new ArrayList();
+    points.add(latLng.latitude);
+    points.add(latLng.longitude);
+
+    final Map<String, Object> data = new HashMap<>();
+    data.put("markerId", googleMarkerId);
+    data.put("position", points);
+    Mockito.verify(methodChannel).invokeMethod("marker#onDragStart", data);
+  }
+
+  @Test
+  public void controller_OnMarkerDragEnd() {
+    final MethodChannel methodChannel =
+        spy(new MethodChannel(mock(BinaryMessenger.class), "no-name", mock(MethodCodec.class)));
+    final MarkersController controller = new MarkersController(methodChannel);
+    final GoogleMap googleMap = mock(GoogleMap.class);
+    controller.setGoogleMap(googleMap);
+
+    final zzt z = mock(zzt.class);
+    final Marker marker = new Marker(z);
+
+    final String googleMarkerId = "abc123";
+
+    when(marker.getId()).thenReturn(googleMarkerId);
+    when(googleMap.addMarker(any(MarkerOptions.class))).thenReturn(marker);
+
+    final LatLng latLng = new LatLng(1.1, 2.2);
+    final Map<String, String> markerOptions = new HashMap();
+    markerOptions.put("markerId", googleMarkerId);
+
+    final List<Object> markers = Arrays.<Object>asList(markerOptions);
+    controller.addMarkers(markers);
+    controller.onMarkerDragEnd(googleMarkerId, latLng);
+
+    final List<Double> points = new ArrayList();
+    points.add(latLng.latitude);
+    points.add(latLng.longitude);
+
+    final Map<String, Object> data = new HashMap<>();
+    data.put("markerId", googleMarkerId);
+    data.put("position", points);
+    Mockito.verify(methodChannel).invokeMethod("marker#onDragEnd", data);
+  }
+
+  @Test
+  public void controller_OnMarkerDrag() {
+    final MethodChannel methodChannel =
+        spy(new MethodChannel(mock(BinaryMessenger.class), "no-name", mock(MethodCodec.class)));
+    final MarkersController controller = new MarkersController(methodChannel);
+    final GoogleMap googleMap = mock(GoogleMap.class);
+    controller.setGoogleMap(googleMap);
+
+    final zzt z = mock(zzt.class);
+    final Marker marker = new Marker(z);
+
+    final String googleMarkerId = "abc123";
+
+    when(marker.getId()).thenReturn(googleMarkerId);
+    when(googleMap.addMarker(any(MarkerOptions.class))).thenReturn(marker);
+
+    final LatLng latLng = new LatLng(1.1, 2.2);
+    final Map<String, String> markerOptions = new HashMap();
+    markerOptions.put("markerId", googleMarkerId);
+
+    final List<Object> markers = Arrays.<Object>asList(markerOptions);
+    controller.addMarkers(markers);
+    controller.onMarkerDrag(googleMarkerId, latLng);
+
+    final List<Double> points = new ArrayList();
+    points.add(latLng.latitude);
+    points.add(latLng.longitude);
+
+    final Map<String, Object> data = new HashMap<>();
+    data.put("markerId", googleMarkerId);
+    data.put("position", points);
+    Mockito.verify(methodChannel).invokeMethod("marker#onDrag", data);
+  }
+}
diff --git a/packages/google_maps_flutter/google_maps_flutter/example/lib/drag_marker.dart b/packages/google_maps_flutter/google_maps_flutter/example/lib/drag_marker.dart
new file mode 100644
index 0000000..2c79291
--- /dev/null
+++ b/packages/google_maps_flutter/google_maps_flutter/example/lib/drag_marker.dart
@@ -0,0 +1,156 @@
+// Copyright 2013 The Flutter Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+// ignore_for_file: public_member_api_docs
+
+import 'dart:math';
+
+import 'package:flutter/material.dart';
+import 'package:google_maps_flutter/google_maps_flutter.dart';
+
+import 'page.dart';
+
+class DragMarkerPage extends GoogleMapExampleAppPage {
+  DragMarkerPage() : super(const Icon(Icons.drag_handle), 'Drag marker');
+
+  @override
+  Widget build(BuildContext context) {
+    return const DragMarkerBody();
+  }
+}
+
+class DragMarkerBody extends StatefulWidget {
+  const DragMarkerBody();
+
+  @override
+  State<StatefulWidget> createState() => DragMarkerBodyState();
+}
+
+typedef MarkerUpdateAction = Marker Function(Marker marker);
+
+class DragMarkerBodyState extends State<DragMarkerBody> {
+  DragMarkerBodyState();
+  static const LatLng center = LatLng(-33.86711, 151.1947171);
+
+  GoogleMapController? controller;
+  Map<MarkerId, Marker> markers = <MarkerId, Marker>{};
+  MarkerId? selectedMarker;
+  int _markerIdCounter = 1;
+  LatLng? markerPosition;
+
+  void _onMapCreated(GoogleMapController controller) {
+    this.controller = controller;
+  }
+
+  void _onMarkerTapped(MarkerId markerId) {
+    final Marker? tappedMarker = markers[markerId];
+    if (tappedMarker != null) {
+      setState(() {
+        if (markers.containsKey(selectedMarker)) {
+          final Marker resetOld = markers[selectedMarker]!
+              .copyWith(iconParam: BitmapDescriptor.defaultMarker);
+          markers[selectedMarker!] = resetOld;
+        }
+        selectedMarker = markerId;
+        final Marker newMarker = tappedMarker.copyWith(
+          iconParam: BitmapDescriptor.defaultMarkerWithHue(
+            BitmapDescriptor.hueGreen,
+          ),
+        );
+        markers[markerId] = newMarker;
+      });
+    }
+  }
+
+  void _onMarkerDrag(MarkerId markerId, LatLng newPosition) async {
+    setState(() {
+      this.markerPosition = newPosition;
+    });
+  }
+
+  void _add() {
+    final int markerCount = markers.length;
+
+    if (markerCount == 12) {
+      return;
+    }
+
+    final String markerIdVal = 'marker_id_$_markerIdCounter';
+    _markerIdCounter++;
+    final MarkerId markerId = MarkerId(markerIdVal);
+
+    final Marker marker = Marker(
+      draggable: true,
+      markerId: markerId,
+      position: LatLng(
+        center.latitude + sin(_markerIdCounter * pi / 6.0) / 20.0,
+        center.longitude + cos(_markerIdCounter * pi / 6.0) / 20.0,
+      ),
+      infoWindow: InfoWindow(title: markerIdVal, snippet: '*'),
+      onTap: () => _onMarkerTapped(markerId),
+      onDrag: (LatLng position) => _onMarkerDrag(markerId, position),
+    );
+
+    setState(() {
+      markers[markerId] = marker;
+    });
+  }
+
+  void _remove() {
+    setState(() {
+      if (markers.containsKey(selectedMarker)) {
+        markers.remove(selectedMarker);
+      }
+    });
+  }
+
+  @override
+  Widget build(BuildContext context) {
+    return Column(
+      mainAxisAlignment: MainAxisAlignment.spaceEvenly,
+      crossAxisAlignment: CrossAxisAlignment.stretch,
+      children: <Widget>[
+        Expanded(
+          child: Center(
+            child: GoogleMap(
+              onMapCreated: _onMapCreated,
+              initialCameraPosition: const CameraPosition(
+                target: center,
+                zoom: 11.0,
+              ),
+              markers: markers.values.toSet(),
+            ),
+          ),
+        ),
+        Container(
+          height: 30,
+          padding: EdgeInsets.only(left: 12, right: 12),
+          child: Row(
+            mainAxisSize: MainAxisSize.max,
+            children: [
+              markerPosition == null
+                  ? Container()
+                  : Expanded(child: Text("lat: ${markerPosition!.latitude}")),
+              markerPosition == null
+                  ? Container()
+                  : Expanded(child: Text("lng: ${markerPosition!.longitude}")),
+            ],
+          ),
+        ),
+        Row(
+          children: <Widget>[
+            TextButton(
+              child: const Text('add'),
+              onPressed: _add,
+            ),
+            TextButton(
+              child: const Text('remove'),
+              onPressed: _remove,
+            ),
+          ],
+        ),
+      ],
+    );
+  }
+}
diff --git a/packages/google_maps_flutter/google_maps_flutter/example/lib/main.dart b/packages/google_maps_flutter/google_maps_flutter/example/lib/main.dart
index 15b14db..16f242c 100644
--- a/packages/google_maps_flutter/google_maps_flutter/example/lib/main.dart
+++ b/packages/google_maps_flutter/google_maps_flutter/example/lib/main.dart
@@ -5,6 +5,7 @@
 // ignore_for_file: public_member_api_docs
 
 import 'package:flutter/material.dart';
+import 'package:google_maps_flutter_example/drag_marker.dart';
 import 'package:google_maps_flutter_example/lite_mode.dart';
 import 'animate_camera.dart';
 import 'map_click.dart';
@@ -34,6 +35,7 @@
   PlacePolylinePage(),
   PlacePolygonPage(),
   PlaceCirclePage(),
+  DragMarkerPage(),
   PaddingPage(),
   SnapshotPage(),
   LiteModePage(),
diff --git a/packages/google_maps_flutter/google_maps_flutter/example/lib/place_marker.dart b/packages/google_maps_flutter/google_maps_flutter/example/lib/place_marker.dart
index 3d083e5..53f553e 100644
--- a/packages/google_maps_flutter/google_maps_flutter/example/lib/place_marker.dart
+++ b/packages/google_maps_flutter/google_maps_flutter/example/lib/place_marker.dart
@@ -30,7 +30,7 @@
   State<StatefulWidget> createState() => PlaceMarkerBodyState();
 }
 
-typedef Marker MarkerUpdateAction(Marker marker);
+typedef MarkerUpdateAction = Marker Function(Marker marker);
 
 class PlaceMarkerBodyState extends State<PlaceMarkerBody> {
   PlaceMarkerBodyState();
diff --git a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapController.m b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapController.m
index be37287..1428de6 100644
--- a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapController.m
+++ b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapController.m
@@ -509,6 +509,16 @@
   [_markersController onMarkerDragEnd:markerId coordinate:marker.position];
 }
 
+- (void)mapView:(GMSMapView*)mapView didStartDraggingMarker:(GMSMarker*)marker {
+  NSString* markerId = marker.userData[0];
+  [_markersController onMarkerDragStart:markerId coordinate:marker.position];
+}
+
+- (void)mapView:(GMSMapView*)mapView didDragMarker:(GMSMarker*)marker {
+  NSString* markerId = marker.userData[0];
+  [_markersController onMarkerDrag:markerId coordinate:marker.position];
+}
+
 - (void)mapView:(GMSMapView*)mapView didTapInfoWindowOfMarker:(GMSMarker*)marker {
   NSString* markerId = marker.userData[0];
   [_markersController onInfoWindowTap:markerId];
diff --git a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.h b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.h
index d3e8354..5625187 100644
--- a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.h
+++ b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.h
@@ -45,7 +45,9 @@
 - (void)changeMarkers:(NSArray*)markersToChange;
 - (void)removeMarkerIds:(NSArray*)markerIdsToRemove;
 - (BOOL)onMarkerTap:(NSString*)markerId;
+- (void)onMarkerDragStart:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate;
 - (void)onMarkerDragEnd:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate;
+- (void)onMarkerDrag:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate;
 - (void)onInfoWindowTap:(NSString*)markerId;
 - (void)showMarkerInfoWindow:(NSString*)markerId result:(FlutterResult)result;
 - (void)hideMarkerInfoWindow:(NSString*)markerId result:(FlutterResult)result;
diff --git a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.m b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.m
index 6a9fb88..51ed825 100644
--- a/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.m
+++ b/packages/google_maps_flutter/google_maps_flutter/ios/Classes/GoogleMapMarkerController.m
@@ -295,6 +295,28 @@
   [_methodChannel invokeMethod:@"marker#onTap" arguments:@{@"markerId" : markerId}];
   return controller.consumeTapEvents;
 }
+- (void)onMarkerDragStart:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate {
+  if (!markerId) {
+    return;
+  }
+  FLTGoogleMapMarkerController* controller = _markerIdToController[markerId];
+  if (!controller) {
+    return;
+  }
+  [_methodChannel invokeMethod:@"marker#onDragStart"
+                     arguments:@{@"markerId" : markerId, @"position" : PositionToJson(coordinate)}];
+}
+- (void)onMarkerDrag:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate {
+  if (!markerId) {
+    return;
+  }
+  FLTGoogleMapMarkerController* controller = _markerIdToController[markerId];
+  if (!controller) {
+    return;
+  }
+  [_methodChannel invokeMethod:@"marker#onDrag"
+                     arguments:@{@"markerId" : markerId, @"position" : PositionToJson(coordinate)}];
+}
 - (void)onMarkerDragEnd:(NSString*)markerId coordinate:(CLLocationCoordinate2D)coordinate {
   if (!markerId) {
     return;
diff --git a/packages/google_maps_flutter/google_maps_flutter/lib/src/controller.dart b/packages/google_maps_flutter/google_maps_flutter/lib/src/controller.dart
index ba18c5f..d57ac97 100644
--- a/packages/google_maps_flutter/google_maps_flutter/lib/src/controller.dart
+++ b/packages/google_maps_flutter/google_maps_flutter/lib/src/controller.dart
@@ -69,6 +69,12 @@
     GoogleMapsFlutterPlatform.instance
         .onMarkerTap(mapId: mapId)
         .listen((MarkerTapEvent e) => _googleMapState.onMarkerTap(e.value));
+    GoogleMapsFlutterPlatform.instance.onMarkerDragStart(mapId: mapId).listen(
+        (MarkerDragStartEvent e) =>
+            _googleMapState.onMarkerDragStart(e.value, e.position));
+    GoogleMapsFlutterPlatform.instance.onMarkerDrag(mapId: mapId).listen(
+        (MarkerDragEvent e) =>
+            _googleMapState.onMarkerDrag(e.value, e.position));
     GoogleMapsFlutterPlatform.instance.onMarkerDragEnd(mapId: mapId).listen(
         (MarkerDragEndEvent e) =>
             _googleMapState.onMarkerDragEnd(e.value, e.position));
diff --git a/packages/google_maps_flutter/google_maps_flutter/lib/src/google_map.dart b/packages/google_maps_flutter/google_maps_flutter/lib/src/google_map.dart
index 26b9d6b..b4ffd22 100644
--- a/packages/google_maps_flutter/google_maps_flutter/lib/src/google_map.dart
+++ b/packages/google_maps_flutter/google_maps_flutter/lib/src/google_map.dart
@@ -8,7 +8,7 @@
 ///
 /// Pass to [GoogleMap.onMapCreated] to receive a [GoogleMapController] when the
 /// map is created.
-typedef void MapCreatedCallback(GoogleMapController controller);
+typedef MapCreatedCallback = void Function(GoogleMapController controller);
 
 // This counter is used to provide a stable "constant" initialization id
 // to the buildView function, so the web implementation can use it as a
@@ -368,6 +368,30 @@
     }
   }
 
+  void onMarkerDragStart(MarkerId markerId, LatLng position) {
+    assert(markerId != null);
+    final Marker? marker = _markers[markerId];
+    if (marker == null) {
+      throw UnknownMapObjectIdError('marker', markerId, 'onDragStart');
+    }
+    final ValueChanged<LatLng>? onDragStart = marker.onDragStart;
+    if (onDragStart != null) {
+      onDragStart(position);
+    }
+  }
+
+  void onMarkerDrag(MarkerId markerId, LatLng position) {
+    assert(markerId != null);
+    final Marker? marker = _markers[markerId];
+    if (marker == null) {
+      throw UnknownMapObjectIdError('marker', markerId, 'onDrag');
+    }
+    final ValueChanged<LatLng>? onDrag = marker.onDrag;
+    if (onDrag != null) {
+      onDrag(position);
+    }
+  }
+
   void onMarkerDragEnd(MarkerId markerId, LatLng position) {
     assert(markerId != null);
     final Marker? marker = _markers[markerId];
diff --git a/packages/google_maps_flutter/google_maps_flutter/pubspec.yaml b/packages/google_maps_flutter/google_maps_flutter/pubspec.yaml
index 641e475..61ac88a 100644
--- a/packages/google_maps_flutter/google_maps_flutter/pubspec.yaml
+++ b/packages/google_maps_flutter/google_maps_flutter/pubspec.yaml
@@ -2,7 +2,7 @@
 description: A Flutter plugin for integrating Google Maps in iOS and Android applications.
 repository: https://github.com/flutter/plugins/tree/master/packages/google_maps_flutter/google_maps_flutter
 issue_tracker: https://github.com/flutter/flutter/issues?q=is%3Aissue+is%3Aopen+label%3A%22p%3A+maps%22
-version: 2.0.10
+version: 2.0.11
 
 environment:
   sdk: ">=2.14.0 <3.0.0"
@@ -21,7 +21,7 @@
   flutter:
     sdk: flutter
   flutter_plugin_android_lifecycle: ^2.0.1
-  google_maps_flutter_platform_interface: ^2.0.0
+  google_maps_flutter_platform_interface: ^2.1.2
 
 dev_dependencies:
   flutter_test:
diff --git a/packages/google_maps_flutter/google_maps_flutter/test/map_creation_test.dart b/packages/google_maps_flutter/google_maps_flutter/test/map_creation_test.dart
index 6e0f5ed..6b3ac90 100644
--- a/packages/google_maps_flutter/google_maps_flutter/test/map_creation_test.dart
+++ b/packages/google_maps_flutter/google_maps_flutter/test/map_creation_test.dart
@@ -230,6 +230,16 @@
   }
 
   @override
+  Stream<MarkerDragStartEvent> onMarkerDragStart({required int mapId}) {
+    return mapEventStreamController.stream.whereType<MarkerDragStartEvent>();
+  }
+
+  @override
+  Stream<MarkerDragEvent> onMarkerDrag({required int mapId}) {
+    return mapEventStreamController.stream.whereType<MarkerDragEvent>();
+  }
+
+  @override
   Stream<MarkerDragEndEvent> onMarkerDragEnd({required int mapId}) {
     return mapEventStreamController.stream.whereType<MarkerDragEndEvent>();
   }