Skip to content

Commit

Permalink
Dependency updates 2024-10 (#65)
Browse files Browse the repository at this point in the history
* Update actions/checkout action to v4

* Update swiftwasm/swiftwasm-action action to v5.9

* Update codecov/codecov-action action to v4

* Update actions/upload-artifact action to v4

* Accumulate all non-major dependency updates into one pull request

* Update CI Xcode versions

* Update pipeline

* Swift 5.10 on windows

* Upload test failure artifacts

* Debug linux CI

* Always

* Swift test help line comment

* Linux testing

* Linux testing

* Upload artifacts

* Include hidden files

* Update testing

* Update tests

* Skip some performance tests on non Mac machines

* Remove XCTestManifest files

* Fix codecov on macOS

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
  • Loading branch information
ctreffs and renovate[bot] authored Oct 9, 2024
1 parent 7ad5a96 commit a5c98c4
Show file tree
Hide file tree
Showing 10 changed files with 77 additions and 591 deletions.
38 changes: 19 additions & 19 deletions .github/workflows/ci-linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,24 +16,24 @@ jobs:
image: swift:${{ matrix.swift }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: "Update APT"
shell: bash
run: "apt update"
- name: "Install curl"
shell: bash
run: "apt-get install -y curl"
- name: Swift version
run: swift --version
uses: actions/checkout@v4

- name: Test
run: swift test -v --skip-update --parallel --enable-test-discovery --enable-code-coverage
- name: Generate coverage report
run: llvm-cov export -format="lcov" .build/debug/*PackageTests.xctest -instr-profile .build/debug/codecov/default.profdata > coverage.lcov
- name: Upload code coverage report
uses: codecov/[email protected]
run: swift test -c release --enable-xctest --parallel --xunit-output .build/xUnit-output.xml

- name: Upload test artifacts
if: failure()
uses: actions/[email protected]
with:
token: ${{secrets.CODECOV_TOKEN}}
file: coverage.lcov
fail_ci_if_error: true
- name: Build Release
run: swift build -c release
name: test-artifacts-linux-${{ matrix.swift }}-${{ github.run_id }}
path: |
.build/*.yaml
.build/*.xml
.build/*.json
.build/*.txt
.build/**/*.xctest
.build/**/*.json
.build/**/*.txt
if-no-files-found: warn
include-hidden-files: true

41 changes: 16 additions & 25 deletions .github/workflows/ci-macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,46 +11,37 @@ jobs:
runs-on: macOS-latest
strategy:
matrix:
xcode: ["13.4.1", "14.2"]
xcode: ["14.3.1", "15.4", "16.0"]
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Select Xcode ${{ matrix.xcode }}
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode }}.app
- name: Test
run: swift test -v --skip-update --parallel --enable-test-discovery --enable-code-coverage
run: swift test -c release --parallel --xunit-output .build/xUnit-output.xml --enable-code-coverage
env:
DEVELOPER_DIR: /Applications/Xcode_${{ matrix.xcode }}.app/Contents/Developer
- name: Upload test artifacts
if: failure()
uses: actions/upload-artifact@v3.1.2
uses: actions/upload-artifact@v4.4.2
with:
name: test-artifacts-${{ matrix.xcode }}-${{ github.run_id }}
path: |
.build/**/*.json
.build/*.yaml
.build/*.xml
.build/*.json
.build/*.txt
.build/**/*.xctest
.build/**/*.json
.build/**/*.txt
if-no-files-found: warn
include-hidden-files: true

- name: Generate coverage report
run: xcrun llvm-cov export -format="lcov" .build/debug/*PackageTests.xctest/Contents/MacOS/*PackageTests -instr-profile .build/debug/codecov/default.profdata > coverage.lcov
run: xcrun llvm-cov export -format="lcov" .build/**/*PackageTests.xctest/Contents/MacOS/*PackageTests -instr-profile .build/**/codecov/default.profdata > coverage.lcov
- name: Upload code coverage report
uses: codecov/codecov-action@v3.1.3
uses: codecov/codecov-action@v4.6.0
with:
token: ${{secrets.CODECOV_TOKEN}}
token: ${{ secrets.CODECOV_TOKEN }}
file: coverage.lcov
fail_ci_if_error: true
- name: Build Release
run: swift build -c release
env:
DEVELOPER_DIR: /Applications/Xcode_${{ matrix.xcode }}.app/Contents/Developer
- name: Upload build artifacts
if: failure()
uses: actions/[email protected]
with:
name: build-artifacts-${{ matrix.xcode }}-${{ github.run_id }}
path: |
*.lcov
.build/*.yaml
.build/**/*.a
.build/**/*.so
.build/**/*.dylib
.build/**/*.dSYM
.build/**/*.json
4 changes: 2 additions & 2 deletions .github/workflows/ci-wasm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ jobs:
wasm-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v4
- name: Build
uses: swiftwasm/swiftwasm-action@v5.8
uses: swiftwasm/swiftwasm-action@v5.9
with:
shell-action: swift build --triple wasm32-unknown-wasi
30 changes: 22 additions & 8 deletions .github/workflows/ci-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,16 +10,30 @@ jobs:
windows-test-build-release:
runs-on: windows-latest
steps:
- uses: compnerd/gha-setup-swift@main
- name: Setup
uses: compnerd/[email protected]
with:
branch: swift-5.7-release
tag: 5.7-RELEASE
branch: swift-5.10-release
tag: 5.10-RELEASE

- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Test
run: swift test -v --skip-update --parallel --enable-test-discovery
run: swift test -c release --parallel --xunit-output .build/xUnit-output.xml

- name: Build Release
run: swift build -c release
- name: Upload test artifacts
if: failure()
uses: actions/[email protected]
with:
name: test-artifacts-windows-${{ github.run_id }}
path: |
.build/*.yaml
.build/*.xml
.build/*.json
.build/*.txt
.build/**/*.xctest
.build/**/*.json
.build/**/*.txt
if-no-files-found: warn
include-hidden-files: true
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
// Created by Christian Treffs on 14.02.19.
//

#if os(macOS)
import FirebladeECS
import XCTest

Expand Down Expand Up @@ -97,3 +98,6 @@ class HashingPerformanceTests: XCTestCase {
#endif
}
}
#else
#warning("Skipping HashingPerformanceTests")
#endif
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
// Created by Christian Treffs on 05.10.19.
//

#if os(macOS)
import FirebladeECS
import XCTest

Expand All @@ -30,7 +31,7 @@ final class TypeIdentifierPerformanceTests: XCTestCase {
/// release: 1.034 sec
/// debug:
func testPerformanceHash() {
measure {
measure(options: .default) {
for _ in 0..<maxIterations {
_ = StringHashing.singer_djb2(String(describing: Color.self))
_ = StringHashing.singer_djb2(String(describing: EmptyComponent.self))
Expand Down Expand Up @@ -91,3 +92,6 @@ final class TypeIdentifierPerformanceTests: XCTestCase {
}
}
}
#else
#warning("Skipping TypeIdentifierPerformanceTests tests")
#endif
70 changes: 0 additions & 70 deletions Tests/FirebladeECSPerformanceTests/XCTestManifests.swift

This file was deleted.

Loading

0 comments on commit a5c98c4

Please sign in to comment.