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

fix windows and macOS ci checks #6519

Merged
merged 7 commits into from
Apr 10, 2024
Merged
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/macos-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: 3.9
python-version: 3.12

- name: Install Homebrew dependencies
run: |
Expand Down
30 changes: 18 additions & 12 deletions .github/workflows/windows-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:

- uses: actions/setup-python@v5
with:
python-version: '3.8'
python-version: '3.12'
- name: Install Craft Master with Nextcloud Client Deps
shell: pwsh
run: |
Expand Down Expand Up @@ -46,6 +46,19 @@ jobs:
run: |
choco install opencppcoverage

- name: Cache Install inkscape
id: cache-install-inkscape
uses: actions/cache@v4
with:
path: C:\Program Files\inkscape
key: ${{ runner.os }}-cache-install-inkscape

- name: Install inkscape
if: steps.cache-install-inkscape.outputs.cache-hit != 'true'
shell: pwsh
run: |
choco install inkscape

- name: Setup PATH
shell: pwsh
run: |
Expand All @@ -62,24 +75,17 @@ jobs:

craft --src-dir ${{ github.workspace }} nextcloud-client

- name: Run tests
- name: Run tests with coverage
shell: pwsh
run: |
function runTestsAndCreateCoverage() {
function runTests() {
$buildFolder = "${{ github.workspace }}\${{ env.CRAFT_TARGET }}\build\nextcloud-client\work\build"

cd $buildFolder

$binFolder = "$buildFolder\bin"

& OpenCppCoverage.exe --optimized_build --quiet --sources ${{ github.workspace }} --modules $binFolder\*.dll* --export_type cobertura:${{ env.COBERTURA_COVERAGE_FILE }} --cover_children -- ctest --output-on-failure --timeout 300
& ctest --output-on-failure --timeout 300
}

runTestsAndCreateCoverage

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v4
with:
token: ${{ secrets.CODECOV_TOKEN }}
directory: ${{ github.workspace }}\cobertura_coverage
fail_ci_if_error: true
runTests
6 changes: 2 additions & 4 deletions craftmaster.ini
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,11 @@ CreateCache = False
# Category is case sensitive
[GeneralSettings]

General/MacDeploymentTarget = 10.15
General/MacDeploymentTarget = 12.0

## This is the location of your python installation.
## This value must be set.
Paths/Python = C:\Python39-x64
Paths/Python27 = C:\Python27-x64
Paths/Python = C:\Python312-x64

Compile/BuildType = RelWithDebInfo

Expand All @@ -32,7 +31,6 @@ ShortPath/EnableJunctions = False

; Packager/RepositoryUrl = https://files.kde.org/craft/
Packager/PackageType = NullsoftInstallerPackager
Packager/RepositoryUrl = https://files.kde.org/craft/master/

ContinuousIntegration/Enabled = True

Expand Down
Loading