Skip to content

Commit 12701ad

Browse files
authored
Merge branch 'main' into fix/googleuser-token-snapshot
2 parents 90e6068 + 969dacd commit 12701ad

2 files changed

Lines changed: 88 additions & 196 deletions

File tree

‎.github/workflows/unit_tests.yml‎

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,21 @@ jobs:
4444
matrix:
4545
os: [macos-15]
4646
sdk: ['macosx', 'iphonesimulator']
47+
# Also run the iOS unit tests with Thread Sanitizer as well.
48+
# It is iOS simulator only: macOS's libobjc inlines the uncontended fast
49+
# path of the lock behind atomic properties, and Thread Sanitizer, which
50+
# only sees lock function calls, then reports false data races on them.
51+
# The simulator's libobjc calls the lock functions, so Thread Sanitizer
52+
# sees the synchronization.
53+
thread-sanitizer: [false, true]
4754
include:
4855
- sdk: 'macosx'
4956
destination: '"platform=OS X,arch=x86_64"'
5057
- sdk: 'iphonesimulator'
5158
destination: '"platform=iOS Simulator,name=iPhone 16,OS=18.6"'
59+
exclude:
60+
- sdk: 'macosx'
61+
thread-sanitizer: true
5262
steps:
5363
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
5464
- name: Select Xcode
@@ -59,14 +69,16 @@ jobs:
5969
-scheme GoogleSignIn-Package \
6070
-sdk ${{ matrix.sdk }} \
6171
-destination ${{ matrix.destination }} \
62-
build-for-testing
72+
build-for-testing \
73+
${{ matrix.thread-sanitizer && '-enableThreadSanitizer YES' || '' }}
6374
- name: Run unit test target
6475
run: |
6576
xcodebuild \
6677
-scheme GoogleSignIn-Package \
6778
-sdk ${{ matrix.sdk }} \
6879
-destination ${{ matrix.destination }} \
69-
test-without-building
80+
test-without-building \
81+
${{ matrix.thread-sanitizer && '-enableThreadSanitizer YES' || '' }}
7082
7183
signin-sample-spm-build:
7284
runs-on: macos-15

0 commit comments

Comments
 (0)