dartDefineConfigJsonMap:<String,Object>{'DART_DEFINES':'Define a variable, but it occupies the variable name of the system'},
dartObfuscation:true,
);
buildInfo.toEnvironmentConfig();
expect(testLogger.warningText,contains('The key: [DART_DEFINES] already exists, you cannot use environment variables that have been used by the system'));
});
testUsingContext('toEnvironmentConfig repeated variable with DART_DEFINES not set',()async{
// Simulate operation flutterCommand.getBuildInfo with `dart-define-from-file` set dartDefines
dartDefines:<String>['DART_DEFINES=Define a variable, but it occupies the variable name of the system'],
trackWidgetCreation:true,
dartDefineConfigJsonMap:<String,Object>{'DART_DEFINES':'Define a variable, but it occupies the variable name of the system'},
dartObfuscation:true,
);
buildInfo.toEnvironmentConfig();
expect(testLogger.warningText,contains('The key: [DART_DEFINES] already exists, you cannot use environment variables that have been used by the system'));