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

GitHub CI pipeline is malformed #433

Closed
MartinZikmund opened this issue Nov 12, 2023 · 1 comment · Fixed by #458
Closed

GitHub CI pipeline is malformed #433

MartinZikmund opened this issue Nov 12, 2023 · 1 comment · Fixed by #458
Assignees
Labels
kind/bug Something isn't working kind/regression Something was working, now it isn't priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now.

Comments

@MartinZikmund
Copy link
Member

MartinZikmund commented Nov 12, 2023

Current behavior

Thew GitHub CI template gets generated invalid:

name: CI

on:
  push:
    branches:
      - main
      - release/**

  pull_request:
    types: [opened, synchronize, reopened]
    branches:
      - main
      - release/**
env:
  STEP_TIMEOUT_MINUTES: 60

jobs:
  smoke_test:
    name: Smoke Test (Debug Build of UnoApp26)
    runs-on: windows-latest
    steps:
      - uses: actions/checkout@v3
        with:
          fetch-depth: 0

      - name: Install Dependencies
        timeout-minutes: ${{ fromJSON(env.STEP_TIMEOUT_MINUTES) }}
        uses: "./.github/steps/install_dependencies"

      # Add  MSBuild to the PATH: https://github.com/microsoft/setup-msbuild
      - name: Setup MSBuild
        uses: microsoft/setup-msbuild@v1.3.1

      - name: Build UnoApp26 (Debug)
        shell: pwsh
        run: msbuild ./UnoApp26/UnoApp26.csproj /r
UnoApp26.Tests (Release)
        shell: pwsh
        run: msbuild ./UnoApp26.Tests/UnoApp26.Tests.csproj /p:Configuration=Release /p:OverrideTargetFrameworks=net8.0 /r

      - name: Run Unit Tests
        shell: pwsh
        run: dotnet test ./UnoApp26.Tests/UnoApp26.Tests.csproj --no-build -c Release --logger GitHubActions --blame-crash --collect:"XPlat Code Coverage" -- DataCollectionRunSettings.DataCollectors.DataCollector.Configuration.Format=opencover
#endif

Note that the whole section starting the incorrectly indented UnoApp26.Tests line should not be there as I did not include tests in the setup (see repro steps below).

Expected behavior

Should be valid YAML

How to reproduce it (as minimally and precisely as possible)

I used the Blank template with .NET 8, all target platforms and GitHub pipeline as CI option. After creation, the ci.yml file was malformed. I tried two times with the same result.

@MartinZikmund MartinZikmund added kind/bug Something isn't working triage/untriaged Indicates an issue requires triaging or verification. labels Nov 12, 2023
@dansiegel dansiegel added kind/regression Something was working, now it isn't priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now. and removed triage/untriaged Indicates an issue requires triaging or verification. labels Nov 13, 2023
@dansiegel dansiegel self-assigned this Nov 13, 2023
@dansiegel
Copy link
Contributor

This should be working, but all of the testing that I've done to fix it isn't making a difference. Waiting on feedback dotnet/templating#7269

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working kind/regression Something was working, now it isn't priority/critical-urgent Highest priority. Must be actively worked on as someone's top priority right now.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants