-
-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* run_all_unit_tests.sh supports selecting a build configuration via argument * GHA - build Debug and Release unit tests in parallel * Trying to unflake the unit test of ChildrenTracker * Working around the flakiness of ExternalToolExecution test * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Setting up ccache * Typo fix * Building only the current architecture for unit tests * First building all unit tests and only then running them * Marked another flaky test * Enabled unit tests on each push
- Loading branch information
1 parent
c030d4a
commit 29975c4
Showing
16 changed files
with
122 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,46 @@ | ||
name: Build and Test | ||
on: [workflow_dispatch] | ||
on: [push, workflow_dispatch] | ||
jobs: | ||
build: | ||
runs-on: [macos-13] | ||
unit-tests: | ||
runs-on: macos-13 | ||
env: | ||
XC_VERSION: ${{ '15.1' }} | ||
CCACHE_COMPRESS: "true" | ||
CCACHE_COMPRESSLEVEL: "10" | ||
CCACHE_MAXSIZE: "400M" | ||
strategy: | ||
matrix: | ||
configuration: ["Debug", "Release"] | ||
steps: | ||
- name: Select latest Xcode | ||
run: "sudo xcode-select -s /Applications/Xcode_$XC_VERSION.app" | ||
- name: Install ccache | ||
run: | | ||
brew install ccache | ||
which ccache | ||
- name: Cache ccache | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/Library/Caches/ccache | ||
key: ccache-${{ github.job }}-${{ matrix.configuration }}-${{ github.run_id }} | ||
restore-keys: ccache-${{ github.job }}-${{ matrix.configuration }} | ||
- uses: actions/checkout@v2 | ||
- name: Build and run unit tests | ||
run: "cd Scripts && ./run_all_unit_tests.sh ${{ matrix.configuration }}" | ||
- name: Show ccache stats | ||
run: "ccache --show-stats --verbose" | ||
- name: Remove old ccache caches | ||
run: | | ||
cd Scripts | ||
./run_all_unit_tests.sh | ||
gh extension install actions/gh-actions-cache | ||
echo "Fetching list of cache key" | ||
cacheKeys=$(gh actions-cache list --key ccache-${{ github.job }}-${{ matrix.configuration }}- | cut -f 1 ) | ||
## Setting this to not fail the workflow while deleting cache keys. | ||
set +e | ||
echo "Deleting caches..." | ||
for cacheKey in $cacheKeys | ||
do | ||
gh actions-cache delete $cacheKey --confirm | ||
done | ||
echo "Done" | ||
env: | ||
GH_TOKEN: ${{ github.token }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
OTHER_LDFLAGS = $(inherited) -lBase | ||
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GTEST_DONT_DEFINE_FAIL=1 GTEST_DONT_DEFINE_SUCCEED=1 | ||
EXECUTABLE_PREFIX= | ||
ONLY_ACTIVE_ARCH=YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
ONLY_ACTIVE_ARCH=YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
OTHER_LDFLAGS = $(inherited) -lgmock -lgtest -lOperations -lRoutedIO -lUtility | ||
LD_RUNPATH_SEARCH_PATHS = @executable_path/ | ||
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GTEST_DONT_DEFINE_FAIL=1 GTEST_DONT_DEFINE_SUCCEED=1 | ||
ONLY_ACTIVE_ARCH=YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
LD_RUNPATH_SEARCH_PATHS = @executable_path/ | ||
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GTEST_DONT_DEFINE_FAIL=1 GTEST_DONT_DEFINE_SUCCEED=1 | ||
OTHER_LDFLAGS = $(inherited) -framework Foundation -framework Cocoa -lUtility -lBase -lPanel -lVFS -lRoutedIO | ||
ONLY_ACTIVE_ARCH=YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GTEST_DONT_DEFINE_FAIL=1 GTEST_DONT_DEFINE_SUCCEED=1 | ||
OTHER_LDFLAGS = $(inherited) -framework Foundation -framework Cocoa -lTerm -lUtility -lBase | ||
ONLY_ACTIVE_ARCH=YES |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
OTHER_LDFLAGS = $(inherited) -lUtility -lBase | ||
GCC_PREPROCESSOR_DEFINITIONS = $(inherited) GTEST_DONT_DEFINE_FAIL=1 GTEST_DONT_DEFINE_SUCCEED=1 | ||
EXECUTABLE_PREFIX= | ||
ONLY_ACTIVE_ARCH=YES |
Oops, something went wrong.