feat: 던전 시스템과 레벨업 로직 추가 #21
Workflow file for this run
This file contains hidden or 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: CI - Build & Test | |
| on: | |
| pull_request: | |
| branches: ["*"] | |
| env: | |
| SOLUTION: Fantasy-server/Fantasy-server.sln | |
| DOTNET_VERSION: 10.0.x | |
| jobs: | |
| build-and-test: | |
| name: Build & Test | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: ${{ env.DOTNET_VERSION }} | |
| - name: Cache NuGet packages | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.nuget/packages | |
| key: ${{ runner.os }}-nuget-${{ hashFiles('**/*.csproj') }} | |
| restore-keys: | | |
| ${{ runner.os }}-nuget- | |
| - name: Restore dependencies | |
| run: dotnet restore ${{ env.SOLUTION }} | |
| - name: Build solution | |
| run: dotnet build ${{ env.SOLUTION }} --no-restore --configuration Release | |
| - name: Run tests with coverage | |
| run: | | |
| dotnet test ${{ env.SOLUTION }} \ | |
| --no-build \ | |
| --configuration Release \ | |
| --collect:"XPlat Code Coverage" \ | |
| --results-directory ./TestResults \ | |
| --logger "trx;LogFileName=test_results.trx" \ | |
| --verbosity minimal | |
| - name: Upload test results | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: test-results | |
| path: ./TestResults | |
| required: | |
| name: CI Required | |
| runs-on: ubuntu-latest | |
| needs: [build-and-test] | |
| if: always() | |
| steps: | |
| - name: Check all jobs passed | |
| run: | | |
| if [[ "${{ needs.build-and-test.result }}" != "success" ]]; then | |
| echo "CI failed — build-and-test: ${{ needs.build-and-test.result }}" | |
| exit 1 | |
| fi | |
| echo "All checks passed" |