Repository: flutter/flutter
File: packages/flutter_tools/test/commands.shard/hermetic/build_ipa_test.dart (Dart)

Code before:
        <key>uploadBitcode</key>
        <false/>
    </dict>
</plist>
''';

      final String actualIpaPlistContents = fileSystem
          .file(cachedExportOptionsPlist)
          .readAsStringSync();
      expect(actualIpaPlistContents, expectedIpaPlistContents);

      expect(logger.statusText, contains('build/ios/archive/Runner.xcarchive'));
      expect(logger.statusText, contains('Building App Store IPA'));
      expect(logger.statusText, contains(RegExp(r'Built IPA to build/ios/ipa \(\d+\.\d+MB\)')));
      expect(logger.statusText, contains('To upload to the App Store'));
      expect(logger.statusText, contains('Apple Transporter macOS app'));
      expect(fakeProcessManager, hasNoRemainingExpectations);
    },
    overrides: <Type, Generator>{
      FileSystem: () => fileSystem,
      Logger: () => logger,
      ProcessManager: () => fakeProcessManager,
      Pub: ThrowingPub.new,
      Platform: () => macosPlatform,
      XcodeProjectInterpreter: () =>
          FakeXcodeProjectInterpreterWithBuildSettings(version: Version(16, null, null)),
      Artifacts: () => Artifacts.test(),
    },
  );

  testUsingContext(
    'ipa build invokes xcodebuild and archives for ad-hoc distribution',
    () async {
      final File cachedExportOptionsPlist = fileSystem.file('/CachedExportOptions.plist');
      final command = BuildCommand(
        androidSdk: FakeAndroidSdk(),
        buildSystem: TestBuildSystem.all(BuildResult(success: true)),
        logger: logger,
        fileSystem: fileSystem,
        osUtils: FakeOperatingSystemUtils(),
      );
      fakeProcessManager.addCommands(<FakeCommand>[
        xattrCommand,
        setUpFakeXcodeBuildHandler(),
        exportArchiveCommand(
          exportOptionsPlist: _exportOptionsPlist,
          cachePlist: cachedExportOptionsPlist,
        ),
      ]);
      createMinimalMockProjectFiles();


Review comment (suggestion):
```suggestion
          XcodeProjectInterpreter: () => FakeXcodeProjectInterpreterWithBuildSettings(),
```

Looks like this test is specifically ensuring the passed in `app-store` is used. The opposite is already tested in `ipa build uses new "app-store-connect" export method when on Xcode versions > 15.3`

Code after:
        <false/>
    </dict>
</plist>
''';

      final String actualIpaPlistContents = fileSystem
          .file(cachedExportOptionsPlist)
          .readAsStringSync();
      expect(actualIpaPlistContents, expectedIpaPlistContents);

      expect(logger.statusText, contains('build/ios/archive/Runner.xcarchive'));
      expect(logger.statusText, contains('Building App Store IPA'));
      expect(logger.statusText, contains(RegExp(r'Built IPA to build/ios/ipa \(\d+\.\d+MB\)')));
      expect(logger.statusText, contains('To upload to the App Store'));
      expect(logger.statusText, contains('Apple Transporter macOS app'));
      expect(fakeProcessManager, hasNoRemainingExpectations);
    },
    overrides: <Type, Generator>{
      FileSystem: () => fileSystem,
      Logger: () => logger,
      ProcessManager: () => fakeProcessManager,
      Pub: ThrowingPub.new,
      Platform: () => macosPlatform,
      XcodeProjectInterpreter: () => FakeXcodeProjectInterpreterWithBuildSettings(),
      Artifacts: () => Artifacts.test(),
    },
  );

  testUsingContext(
    'ipa build invokes xcodebuild and archives for ad-hoc distribution',
    () async {
      final File cachedExportOptionsPlist = fileSystem.file('/CachedExportOptions.plist');
      final command = BuildCommand(
        androidSdk: FakeAndroidSdk(),
        buildSystem: TestBuildSystem.all(BuildResult(success: true)),
        logger: logger,
        fileSystem: fileSystem,
        osUtils: FakeOperatingSystemUtils(),
      );
      fakeProcessManager.addCommands(<FakeCommand>[
        xattrCommand,
        setUpFakeXcodeBuildHandler(),
        exportArchiveCommand(
          exportOptionsPlist: _exportOptionsPlist,
          cachePlist: cachedExportOptionsPlist,
        ),
      ]);
      createMinimalMockProjectFiles();

      await createTestCommandRunner(
        command,