update feed url #14
Workflow file for this run
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
name: tests | |
on: | |
push: | |
branches: | |
- develop | |
- main | |
- feature/* | |
pull_request: | |
branches: | |
- develop | |
- main | |
workflow_call: | |
workflow_dispatch: | |
jobs: | |
windows-tests: | |
runs-on: windows-2022 | |
env: | |
USERNAME: nzbgetcom | |
FEED_URL: https://nuget.pkg.github.com/nzbgetcom/nzbget-vcpkg-x64-windows-static-minimal/index.json | |
VCPKG_BINARY_SOURCES: "clear;nuget,https://nuget.pkg.github.com/nzbgetcom/nzbget-vcpkg-x64-windows-static-minimal/index.json" | |
VCPKG_DEFAULT_TRIPLET: "x64-windows-static" | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Add NuGet sources | |
run: | | |
.$(vcpkg fetch nuget) ` | |
sources add ` | |
-Source "${{ env.FEED_URL }}" ` | |
-StorePasswordInClearText ` | |
-Name GitHubPackages ` | |
-UserName "${{ env.USERNAME }}" ` | |
-Password "${{ github.token }}" | |
.$(vcpkg fetch nuget) ` | |
setapikey "${{ github.token }}" ` | |
-Source "${{ env.FEED_URL }}" | |
- name: Setup vcpkg packages | |
run: | | |
vcpkg install openssl libxml2 zlib boost-json boost-asio boost-test --binarysource="${{ env.VCPKG_BINARY_SOURCES }}" | |
- name: Build | |
run: | | |
mkdir build | |
cd build | |
cmake .. -DCMAKE_TOOLCHAIN_FILE=C:\vcpkg\scripts\buildsystems\vcpkg.cmake -DVCPKG_TARGET_TRIPLET=${{ env.VCPKG_DEFAULT_TRIPLET }} -DBUILD_ONLY_TESTS=ON | |
cmake --build . --config Release -j 4 | |
- name: Test | |
run: | | |
cd build | |
ctest -C Release | |
- name: Upload test artifacts | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: nzbget-windows-test-log | |
path: build/Testing/Temporary/LastTest.log | |
retention-days: 5 | |
linux-tests: | |
if: false | |
runs-on: ubuntu-24.04 | |
steps: | |
- name: Prepare environment | |
run: | | |
sudo apt-get install cmake libxml2-dev libssl-dev libncurses-dev libboost-all-dev | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
mkdir build | |
cd build | |
cmake .. -DBUILD_ONLY_TESTS=ON | |
cmake --build . --config Release -j 4 | |
- name: Test | |
run: | | |
cd build | |
ctest -C Release | |
- name: Upload test artifacts | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: nzbget-linux-test-log | |
path: build/Testing/Temporary/LastTest.log | |
retention-days: 5 | |
macos-tests: | |
if: false | |
runs-on: macos-14 | |
steps: | |
- name: Install dependencies | |
run: | |
brew install boost openssl@3 cmake | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
run: | | |
mkdir build | |
cd build | |
cmake .. -DBUILD_ONLY_TESTS=ON -DDISABLE_CURSES=ON | |
cmake --build . --config Release -j 4 | |
- name: Test | |
run: | | |
cd build | |
ctest -C Release | |
- name: Upload test artifacts | |
uses: actions/upload-artifact@v4 | |
if: failure() | |
with: | |
name: nzbget-linux-test-log | |
path: build/Testing/Temporary/LastTest.log | |
retention-days: 5 |