From dbd3f43fa3e708a20a43f40a8432d2324677ca43 Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Sat, 22 Aug 2026 14:24:23 +0000 Subject: [PATCH] test: add out-of-bounds alpha assertion test for MKTileOverlay Co-authored-by: esenmx <43244505+esenmx@users.noreply.github.com> --- test/mk_tile_overlay_test.dart | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/test/mk_tile_overlay_test.dart b/test/mk_tile_overlay_test.dart index 976f36e..c98b3fa 100644 --- a/test/mk_tile_overlay_test.dart +++ b/test/mk_tile_overlay_test.dart @@ -50,6 +50,24 @@ void main() { ), ).throws(); }); + + test('rejects out of bounds alpha values', () { + check( + () => MKTileOverlay( + id: const MKTileOverlayId('bad'), + urlTemplate: 'https://t/{z}/{x}/{y}.png', + alpha: -0.1, + ), + ).throws(); + + check( + () => MKTileOverlay( + id: const MKTileOverlayId('bad'), + urlTemplate: 'https://t/{z}/{x}/{y}.png', + alpha: 1.1, + ), + ).throws(); + }); }); group('equality', () {