diff --git a/packages/flutter_tools/lib/src/features.dart b/packages/flutter_tools/lib/src/features.dart index 74a3116b4d4..1562375c785 100644 --- a/packages/flutter_tools/lib/src/features.dart +++ b/packages/flutter_tools/lib/src/features.dart @@ -196,6 +196,12 @@ const Feature flutterCustomDevicesFeature = Feature( master: FeatureChannelSetting( available: true, ), + beta: FeatureChannelSetting( + available: true, + ), + stable: FeatureChannelSetting( + available: true, + ), ); /// The fast hot reload feature for https://github.com/flutter/flutter/issues/61407. diff --git a/packages/flutter_tools/test/general.shard/features_test.dart b/packages/flutter_tools/test/general.shard/features_test.dart index c8e20365594..569ff1699d6 100644 --- a/packages/flutter_tools/test/general.shard/features_test.dart +++ b/packages/flutter_tools/test/general.shard/features_test.dart @@ -384,5 +384,20 @@ void main() { }); } + // Custom devices on all channels + for (final String channel in ['master', 'beta', 'stable']) { + testWithoutContext('Custom devices are enabled with flag on $channel', () { + final FeatureFlags featureFlags = createFlags(channel); + testConfig.setValue('enable-custom-devices', true); + expect(featureFlags.areCustomDevicesEnabled, true); + }); + + testWithoutContext('Custom devices are enabled with environment variable on $channel', () { + final FeatureFlags featureFlags = createFlags(channel); + platform.environment = {'FLUTTER_CUSTOM_DEVICES': 'true'}; + expect(featureFlags.areCustomDevicesEnabled, true); + }); + } + }); }