Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch to macos-14 for the Darwin runners. #35704

Draft
wants to merge 5 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ jobs:

build_darwin:
name: Build on Darwin (clang, python_lib, simulated)
runs-on: macos-13
runs-on: macos-14
if: github.actor != 'restyled-io[bot]'

steps:
Expand Down
51 changes: 26 additions & 25 deletions .github/workflows/darwin-tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,10 @@ jobs:
# it.
BUILD_VARIANT_FRAMEWORK_TOOL: no-ble
LSAN_OPTIONS: detect_leaks=1 malloc_context_size=40 suppressions=scripts/tests/chiptest/lsan-mac-suppressions.txt
DARWIN_ARCH: "arm64"

if: github.actor != 'restyled-io[bot]'
runs-on: macos-13
runs-on: macos-14

steps:
- name: Checkout
Expand Down Expand Up @@ -85,17 +86,17 @@ jobs:
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target darwin-x64-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL} \
--target darwin-x64-all-clusters-${BUILD_VARIANT} \
--target darwin-x64-lock-${BUILD_VARIANT} \
--target darwin-x64-ota-provider-${BUILD_VARIANT} \
--target darwin-x64-ota-requestor-${BUILD_VARIANT} \
--target darwin-x64-tv-app-${BUILD_VARIANT} \
--target darwin-x64-bridge-${BUILD_VARIANT} \
--target darwin-x64-lit-icd-${BUILD_VARIANT} \
--target darwin-x64-microwave-oven-${BUILD_VARIANT} \
--target darwin-x64-rvc-${BUILD_VARIANT} \
--target darwin-x64-network-manager-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL} \
--target darwin-${DARWIN_ARCH}-all-clusters-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-lock-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-ota-provider-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-ota-requestor-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-tv-app-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-bridge-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-lit-icd-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-microwave-oven-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-rvc-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-network-manager-${BUILD_VARIANT} \
build \
--copy-artifacts-to objdir-clone \
"
Expand All @@ -104,28 +105,28 @@ jobs:
./scripts/run_in_build_env.sh \
"./scripts/tests/run_test_suite.py \
--runner darwin_framework_tool_python \
--chip-tool ./out/darwin-x64-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin-framework-tool \
--chip-tool ./out/darwin-${DARWIN_ARCH}-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin-framework-tool \
--target-skip-glob '{TestAccessControlConstraints}' \
run \
--iterations 1 \
--test-timeout-seconds 120 \
--all-clusters-app ./out/darwin-x64-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
--lock-app ./out/darwin-x64-lock-${BUILD_VARIANT}/chip-lock-app \
--ota-provider-app ./out/darwin-x64-ota-provider-${BUILD_VARIANT}/chip-ota-provider-app \
--ota-requestor-app ./out/darwin-x64-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--tv-app ./out/darwin-x64-tv-app-${BUILD_VARIANT}/chip-tv-app \
--bridge-app ./out/darwin-x64-bridge-${BUILD_VARIANT}/chip-bridge-app \
--microwave-oven-app ./out/darwin-x64-microwave-oven-${BUILD_VARIANT}/chip-microwave-oven-app \
--rvc-app ./out/darwin-x64-rvc-${BUILD_VARIANT}/chip-rvc-app \
--network-manager-app ./out/darwin-x64-network-manager-${BUILD_VARIANT}/matter-network-manager-app \
--all-clusters-app ./out/darwin-${DARWIN_ARCH}-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
--lock-app ./out/darwin-${DARWIN_ARCH}-lock-${BUILD_VARIANT}/chip-lock-app \
--ota-provider-app ./out/darwin-${DARWIN_ARCH}-ota-provider-${BUILD_VARIANT}/chip-ota-provider-app \
--ota-requestor-app ./out/darwin-${DARWIN_ARCH}-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--tv-app ./out/darwin-${DARWIN_ARCH}-tv-app-${BUILD_VARIANT}/chip-tv-app \
--bridge-app ./out/darwin-${DARWIN_ARCH}-bridge-${BUILD_VARIANT}/chip-bridge-app \
--microwave-oven-app ./out/darwin-${DARWIN_ARCH}-microwave-oven-${BUILD_VARIANT}/chip-microwave-oven-app \
--rvc-app ./out/darwin-${DARWIN_ARCH}-rvc-${BUILD_VARIANT}/chip-rvc-app \
--network-manager-app ./out/darwin-${DARWIN_ARCH}-network-manager-${BUILD_VARIANT}/matter-network-manager-app \
"
- name: Run OTA Test
run: |
./scripts/run_in_build_env.sh \
"./scripts/tests/run_darwin_framework_ota_test.py \
run \
--darwin-framework-tool ./out/darwin-x64-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin-framework-tool \
--ota-requestor-app ./out/darwin-x64-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--darwin-framework-tool ./out/darwin-${DARWIN_ARCH}-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin-framework-tool \
--ota-requestor-app ./out/darwin-${DARWIN_ARCH}-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--ota-data-file /tmp/rawImage \
--ota-image-file /tmp/otaImage \
--ota-destination-file /tmp/downloadedImage \
Expand All @@ -150,7 +151,7 @@ jobs:
if: ${{ failure() && !env.ACT }}
with:
name: framework-build-log-darwin-${BUILD_VARIANT_FRAMEWORK_TOOL}
path: out/darwin-x64-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin_framework_build.log
path: out/darwin-${DARWIN_ARCH}-darwin-framework-tool-${BUILD_VARIANT_FRAMEWORK_TOOL}/darwin_framework_build.log
- name: Uploading objdir for debugging
uses: actions/upload-artifact@v4
if: ${{ failure() && !env.ACT }}
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/darwin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
framework:
name: Build framework
if: github.actor != 'restyled-io[bot]'
runs-on: macos-13
runs-on: macos-14
strategy:
matrix:
options: # We don't need a full matrix
Expand Down Expand Up @@ -73,7 +73,7 @@ jobs:
name: Run framework tests
if: github.actor != 'restyled-io[bot]'
needs: [framework] # serialize to avoid running to many parallel macos runners
runs-on: macos-13
runs-on: macos-14
strategy:
matrix:
options: # We don't need a full matrix
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/example-tv-casting-darwin.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
tv-casting-bridge:
name: Build TV Casting Bridge example
if: github.actor != 'restyled-io[bot]'
runs-on: macos-13
runs-on: macos-14
steps:
- name: Checkout
uses: actions/checkout@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/fuzzing-build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ jobs:

build_darwin_fuzzing:
name: Build on Darwin
runs-on: macos-13
runs-on: macos-14
if: github.actor != 'restyled-io[bot]'

steps:
Expand All @@ -87,7 +87,7 @@ jobs:
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target darwin-x64-all-clusters-no-ble-asan-libfuzzer-clang \
--target darwin-arm64-all-clusters-no-ble-asan-libfuzzer-clang \
build \
--copy-artifacts-to objdir-clone \
"
Expand Down
53 changes: 27 additions & 26 deletions .github/workflows/tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -338,9 +338,10 @@ jobs:
CHIP_TOOL_VARIANT: ${{matrix.chip_tool}}
TSAN_OPTIONS: "halt_on_error=1"
LSAN_OPTIONS: detect_leaks=1 suppressions=scripts/tests/chiptest/lsan-mac-suppressions.txt
DARWIN_ARCH: "arm64"

if: github.actor != 'restyled-io[bot]'
runs-on: macos-13
runs-on: macos-14

steps:
- name: Checkout
Expand All @@ -366,17 +367,17 @@ jobs:
run: |
./scripts/run_in_build_env.sh \
"./scripts/build/build_examples.py \
--target darwin-x64-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT} \
--target darwin-x64-all-clusters-${BUILD_VARIANT} \
--target darwin-x64-lock-${BUILD_VARIANT} \
--target darwin-x64-ota-provider-${BUILD_VARIANT} \
--target darwin-x64-ota-requestor-${BUILD_VARIANT} \
--target darwin-x64-tv-app-${BUILD_VARIANT} \
--target darwin-x64-bridge-${BUILD_VARIANT} \
--target darwin-x64-lit-icd-${BUILD_VARIANT} \
--target darwin-x64-microwave-oven-${BUILD_VARIANT} \
--target darwin-x64-rvc-${BUILD_VARIANT} \
--target darwin-x64-network-manager-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-all-clusters-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-lock-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-ota-provider-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-ota-requestor-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-tv-app-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-bridge-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-lit-icd-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-microwave-oven-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-rvc-${BUILD_VARIANT} \
--target darwin-${DARWIN_ARCH}-network-manager-${BUILD_VARIANT} \
build \
--copy-artifacts-to objdir-clone \
"
Expand All @@ -386,21 +387,21 @@ jobs:
./scripts/run_in_build_env.sh \
"./scripts/tests/run_test_suite.py \
--runner chip_tool_python \
--chip-tool ./out/darwin-x64-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT}/chip-tool \
--chip-tool ./out/darwin-${DARWIN_ARCH}-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT}/chip-tool \
--target-skip-glob '{Test_TC_DGTHREAD_2_1,Test_TC_DGTHREAD_2_2,Test_TC_DGTHREAD_2_3,Test_TC_DGTHREAD_2_4}' \
run \
--iterations 1 \
--test-timeout-seconds 120 \
--all-clusters-app ./out/darwin-x64-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
--lock-app ./out/darwin-x64-lock-${BUILD_VARIANT}/chip-lock-app \
--ota-provider-app ./out/darwin-x64-ota-provider-${BUILD_VARIANT}/chip-ota-provider-app \
--ota-requestor-app ./out/darwin-x64-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--tv-app ./out/darwin-x64-tv-app-${BUILD_VARIANT}/chip-tv-app \
--bridge-app ./out/darwin-x64-bridge-${BUILD_VARIANT}/chip-bridge-app \
--lit-icd-app ./out/darwin-x64-lit-icd-${BUILD_VARIANT}/lit-icd-app \
--microwave-oven-app ./out/darwin-x64-microwave-oven-${BUILD_VARIANT}/chip-microwave-oven-app \
--rvc-app ./out/darwin-x64-rvc-${BUILD_VARIANT}/chip-rvc-app \
--network-manager-app ./out/darwin-x64-network-manager-${BUILD_VARIANT}/matter-network-manager-app \
--all-clusters-app ./out/darwin-${DARWIN_ARCH}-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
--lock-app ./out/darwin-${DARWIN_ARCH}-lock-${BUILD_VARIANT}/chip-lock-app \
--ota-provider-app ./out/darwin-${DARWIN_ARCH}-ota-provider-${BUILD_VARIANT}/chip-ota-provider-app \
--ota-requestor-app ./out/darwin-${DARWIN_ARCH}-ota-requestor-${BUILD_VARIANT}/chip-ota-requestor-app \
--tv-app ./out/darwin-${DARWIN_ARCH}-tv-app-${BUILD_VARIANT}/chip-tv-app \
--bridge-app ./out/darwin-${DARWIN_ARCH}-bridge-${BUILD_VARIANT}/chip-bridge-app \
--lit-icd-app ./out/darwin-${DARWIN_ARCH}-lit-icd-${BUILD_VARIANT}/lit-icd-app \
--microwave-oven-app ./out/darwin-${DARWIN_ARCH}-microwave-oven-${BUILD_VARIANT}/chip-microwave-oven-app \
--rvc-app ./out/darwin-${DARWIN_ARCH}-rvc-${BUILD_VARIANT}/chip-rvc-app \
--network-manager-app ./out/darwin-${DARWIN_ARCH}-network-manager-${BUILD_VARIANT}/matter-network-manager-app \
"

- name: Run purposeful failure tests using the python parser sending commands to chip-tool
Expand All @@ -409,13 +410,13 @@ jobs:
"./scripts/tests/run_test_suite.py \
--runner chip_tool_python \
--include-tags PURPOSEFUL_FAILURE \
--chip-tool ./out/darwin-x64-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT}/chip-tool \
--chip-tool ./out/darwin-${DARWIN_ARCH}-chip-tool${CHIP_TOOL_VARIANT}-${BUILD_VARIANT}/chip-tool \
run \
--iterations 1 \
--expected-failures 3 \
--keep-going \
--test-timeout-seconds 120 \
--all-clusters-app ./out/darwin-x64-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
--all-clusters-app ./out/darwin-${DARWIN_ARCH}-all-clusters-${BUILD_VARIANT}/chip-all-clusters-app \
"

- name: Uploading core files
Expand Down Expand Up @@ -559,7 +560,7 @@ jobs:
TSAN_OPTIONS: "halt_on_error=1"

if: github.actor != 'restyled-io[bot]' && false
runs-on: macos-13
runs-on: macos-14

steps:
- name: Checkout
Expand Down
2 changes: 2 additions & 0 deletions scripts/tests/chiptest/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ def _GetExtraSlowTests() -> Set[str]:
def _GetInDevelopmentTests() -> Set[str]:
"""Tests that fail in YAML for some reason."""
return {
"TestSystemCommissioner", # just testing
"Test_TC_PSCFG_1_1.yaml", # Power source configuration cluster is deprecated and removed from all-clusters
"Test_TC_PSCFG_2_1.yaml", # Power source configuration cluster is deprecated and removed from all-clusters
"Test_TC_PSCFG_2_2.yaml", # Power source configuration cluster is deprecated and removed from all-clusters
Expand Down Expand Up @@ -170,6 +171,7 @@ def _GetChipToolUnsupportedTests() -> Set[str]:
def _GetDarwinFrameworkToolUnsupportedTests() -> Set[str]:
"""Tests that fail in darwin-framework-tool for some reason"""
return {
"TestSystemCommissioner", # just testing
"DL_LockUnlock", # darwin-framework-tool does not currently support reading or subscribing to Events
"DL_UsersAndCredentials", # darwin-framework-tool does not currently support reading or subscribing to Events
"Test_AddNewFabricFromExistingFabric", # darwin-framework-tool does not support the GetCommissionerRootCertificate command.
Expand Down
23 changes: 20 additions & 3 deletions scripts/tests/chiptest/test_definition.py
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,32 @@ def stop(self):
return False

def factoryReset(self):
reset_start = time.monotonic()
logging.error("FACTORY RESET: %s" % self.command)
logging.error("self.killed: %s" % self.killed)
stop_start = time.monotonic()
wasRunning = (not self.killed) and self.stop()
stop_end = time.monotonic()
logging.error("wasRunning: %s, took %s to stop" % (wasRunning, stop_end - stop_start))

for kvs in self.kvsPathSet:
if os.path.exists(kvs):
unlink_start = time.monotonic()
os.unlink(kvs)
unlink_end = time.monotonic()
logging.error("UNLINKING: %s, took %s" % (kvs, unlink_start - unlink_end))

if wasRunning:
return self.start()

start_start = time.monotonic()
started = self.start()
start_end = time.monotonic()
logging.error("STARTED: %s in %s" % (started, start_end - start_start))
reset_end = time.monotonic()
logging.error("RESET DONE, took %s" % (reset_end - reset_start))
return started

reset_end = time.monotonic()
logging.error("RESET DONE, took %s" % (reset_end - reset_start))
return True

def waitForAnyAdvertisement(self):
Expand Down Expand Up @@ -161,7 +178,7 @@ def __terminateProcess(self):
try:
self.process.wait(10)
except subprocess.TimeoutExpired:
logging.debug('Subprocess did not terminate on SIGTERM, killing it now')
logging.error('Subprocess did not terminate on SIGTERM, killing it now')
self.process.kill()
self.process.wait(10)
self.process = None
Expand Down
1 change: 1 addition & 0 deletions src/app/tests/suites/TestSystemCommands.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ config:
nodeId: 0x12344321
cluster: "SystemCommands"
endpoint: 0
timeout: 180
payload:
type: char_string
defaultValue: "MT:-24J0IX4122-.548G00" # This value needs to be generated
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -827,7 +827,7 @@ - (void)test004_Subscribe
}];

// Wait for report
[self waitForExpectationsWithTimeout:kTimeoutInSeconds handler:nil];
[self waitForExpectationsWithTimeout:kTimeoutInSeconds*5 handler:nil];

XCTestExpectation * clearExpectation = [self expectationWithDescription:@"report handlers deregistered"];
[device deregisterReportHandlersWithQueue:queue
Expand Down
Loading