Skip to content

Conversation

@jmagman
Copy link
Member

@jmagman jmagman commented Jan 15, 2026

Part of flutter/flutter#180787

◇ Test run started.
↳ Testing Library Version: 102 (arm64-apple-ios13.0-simulator)
◇ Suite LocalAuthPluginTests started.
◇ Test failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:) started.
◇ Test getEnrolledBiometricsWithTouchID() started.
◇ Test successfullAuthWithBiometrics() started.
◇ Test deviceSupportsBiometrics_withEnrolledHardware() started.
◇ Test deviceSupportsBiometrics_withBiometryNotAvailable() started.
◇ Test deviceSupportsBiometrics_withNonEnrolledHardware() started.
◇ Test failedAuthWithCanEvaluateError(error:expectedResult:) started.
◇ Test localizedFallbackTitle() started.
◇ Test deviceSupportsBiometrics_withBiometryNotAvailableWhenPermissionsDenied() started.
◇ Test successfullAuthWithoutBiometrics() started.
◇ Test getEnrolledBiometricsWithoutEnrolledHardware() started.
◇ Test skippedLocalizedFallbackTitle() started.
◇ Test isDeviceSupportedHandlesSupported() started.
◇ Passing 3 arguments errorCode → -9, expectedResult → .appCancel, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Test getEnrolledBiometricsWithFaceID() started.
◇ Passing 3 arguments errorCode → -1, expectedResult → .authenticationFailed, expectBiometrics → true to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 3 arguments errorCode → -4, expectedResult → .systemCancel, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 3 arguments errorCode → 99, expectedResult → .unknownError, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 3 arguments errorCode → -2, expectedResult → .userCancel, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 3 arguments errorCode → -3, expectedResult → .userFallback, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 3 arguments errorCode → -1, expectedResult → .authenticationFailed, expectBiometrics → false to failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:)
◇ Passing 2 arguments error → LAError(rawValue: -8), expectedResult → .biometryLockout to failedAuthWithCanEvaluateError(error:expectedResult:)
◇ Passing 2 arguments error → LAError(rawValue: -6), expectedResult → .biometryNotAvailable to failedAuthWithCanEvaluateError(error:expectedResult:)
◇ Test isDeviceSupportedHandlesUnsupported() started.
◇ Passing 2 arguments error → LAError(rawValue: -7), expectedResult → .biometryNotEnrolled to failedAuthWithCanEvaluateError(error:expectedResult:)
◇ Passing 2 arguments error → LAError(rawValue: -10), expectedResult → .invalidContext to failedAuthWithCanEvaluateError(error:expectedResult:)
◇ Passing 2 arguments error → LAError(rawValue: -5), expectedResult → .passcodeNotSet to failedAuthWithCanEvaluateError(error:expectedResult:)
◇ Passing 2 arguments error → LAError(rawValue: -1004), expectedResult → .notInteractive to failedAuthWithCanEvaluateError(error:expectedResult:)
​​​​​✔ Test getEnrolledBiometricsWithTouchID() passed after 0.041 seconds.
​✔ Test deviceSupportsBiometrics_withBiometryNotAvailable() passed after 0.041 seconds.
​✔ Test deviceSupportsBiometrics_withBiometryNotAvailableWhenPermissionsDenied() passed after 0.041 seconds.
​✔ Test deviceSupportsBiometrics_withNonEnrolledHardware() passed after 0.041 seconds.
​✔ Test isDeviceSupportedHandlesSupported() passed after 0.041 seconds.
✔ Test getEnrolledBiometricsWithoutEnrolledHardware() passed after 0.041 seconds.
​✔ Test deviceSupportsBiometrics_withEnrolledHardware() passed after 0.041 seconds.
✔ Test failedAuthWithCanEvaluateError(error:expectedResult:) passed after 0.041 seconds.
​✔ Test getEnrolledBiometricsWithFaceID() passed after 0.041 seconds.
✔ Test successfullAuthWithBiometrics() passed after 0.041 seconds.
✔ Test isDeviceSupportedHandlesUnsupported() passed after 0.002 seconds.
​​✔ Test successfullAuthWithoutBiometrics() passed after 0.042 seconds.
✔ Test failedAuthWithEvaluateError(errorCode:expectedResult:expectBiometrics:) passed after 0.042 seconds.
✔ Test skippedLocalizedFallbackTitle() passed after 0.042 seconds.
✔ Test localizedFallbackTitle() passed after 0.042 seconds.
✔ Suite LocalAuthPluginTests passed after 0.042 seconds.
✔ Test run with 15 tests passed after 0.042 seconds.

https://logs.chromium.org/logs/flutter/buildbucket/cr-buildbucket/8692498766458966161/+/u/Run_package_tests/native_test/stdout

Adding CHANGELOG override per #10761 (comment)

Pre-Review Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

Footnotes

  1. Regular contributors who have demonstrated familiarity with the repository guidelines only need to comment if the PR is not auto-exempted by repo tooling. 2 3

@jmagman jmagman self-assigned this Jan 15, 2026
@jmagman jmagman added the override: no changelog needed Override the check requiring CHANGELOG updates for most changes label Jan 15, 2026
@MainActor
func testFailedAuthWithErrorBiometricLockout() {
@Test(arguments: [
(LAError.biometryLockout, AuthResult.biometryLockout),
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Satisfying.

@jmagman jmagman changed the base branch from main to dependabot/gradle/packages/shared_preferences/shared_preferences_android/android/androidx.datastore-datastore-preferences-1.2.0 January 16, 2026 19:58
@jmagman jmagman changed the base branch from dependabot/gradle/packages/shared_preferences/shared_preferences_android/android/androidx.datastore-datastore-preferences-1.2.0 to main January 16, 2026 19:58
@jmagman jmagman marked this pull request as ready for review January 16, 2026 20:30
Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request successfully migrates the local_auth_darwin tests from XCTest to the new Swift Testing framework. The changes are well-executed, leveraging modern features like parameterized tests with @Test(arguments:) to significantly reduce boilerplate and improve test clarity. The adoption of async/await with withCheckedContinuation for handling asynchronous callbacks is also a great improvement. I've left a couple of minor suggestions to fix typos in test function names. Overall, this is an excellent modernization of the test suite.

@MainActor
func testSuccessfullAuthWithBiometrics() throws {
@Test
func successfullAuthWithBiometrics() async {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

There's a typo in the function name. It should be successfulAuthWithBiometrics.

Suggested change
func successfullAuthWithBiometrics() async {
func successfulAuthWithBiometrics() async {

Copy link
Contributor

@LouiseHsu LouiseHsu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The amount of lines removed 😻

Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com>
@jmagman jmagman added the autosubmit Merge PR when tree becomes green via auto submit App label Jan 16, 2026
@auto-submit auto-submit bot merged commit 96de64a into flutter:main Jan 16, 2026
81 checks passed
@jmagman jmagman deleted the local-auth-st branch January 16, 2026 21:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App override: no changelog needed Override the check requiring CHANGELOG updates for most changes p: local_auth platform-ios platform-macos

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants