Update teapot.vcxproj #46
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: build | |
on: | |
push: | |
branches: ["main"] | |
pull_request: | |
branches: ["main"] | |
jobs: | |
build: | |
strategy: | |
matrix: | |
os: [ubuntu-latest, windows-latest] | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Build on Ubuntu | |
if: runner.os == 'Linux' | |
run: make | |
- name: Upload teapot binary | |
if: runner.os == 'Linux' | |
uses: actions/upload-artifact@v2 | |
with: | |
name: teapot-binary | |
path: ./teapot | |
- name: Setup Build Environment on Windows | |
if: runner.os == 'Windows' | |
uses: microsoft/setup-msbuild@v1 | |
with: | |
msbuild-version: 'latest' | |
- name: Build on Windows with MSBuild | |
if: runner.os == 'Windows' | |
run: | | |
msbuild teapot.sln /p:Configuration=Release /p:Platform="x64" /p:CXXStandard=20 /p:LanguageStandard=C++20 | |
test: | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Download teapot binary | |
uses: actions/download-artifact@v2 | |
with: | |
name: teapot-binary | |
path: . | |
- name: Set execute permissions on teapot | |
run: chmod +x ./teapot | |
- name: Run endpoint tests | |
run: | | |
./teapot 8888 & | |
sleep 5 | |
./tests/e2e_tests.sh |