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', () {