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

Migrate HealthChecks.SqlServer tests to Testcontainers #2348

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

Alirexaa
Copy link
Collaborator

What this PR does / why we need it:

Which issue(s) this PR fixes:

Contributes to #2335

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

Please make sure you've completed the relevant tasks for this PR, out of the following list:

  • Code compiles correctly
  • Created/updated tests
  • Unit tests passing
  • End-to-end tests passing
  • Extended the documentation
  • Provided sample for the feature

@github-actions github-actions bot added the github_actions Pull requests that update Github_actions code label Dec 17, 2024
@Alirexaa Alirexaa self-assigned this Dec 17, 2024
@Alirexaa Alirexaa mentioned this pull request Dec 17, 2024
71 tasks
@Alirexaa Alirexaa requested a review from adamsitnik December 17, 2024 14:29
Copy link
Collaborator

@adamsitnik adamsitnik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall it looks great, but it would be nice if we could simplify the yml file and reuse the pattern in other PRs (so introducing changes in the future like updating to .NET 10 requires even fewer changes).

Thank you @Alirexaa !

@@ -30,14 +30,6 @@ on:
jobs:
build:
runs-on: ubuntu-latest
services:
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seeing this change made me realize that we now may be able to do some yaml refactoring and reuse the https://github.com/Xabaril/AspNetCore.Diagnostics.HealthChecks/blob/master/.github/workflows/reusable_ci_workflow.yml file.

The jobs part for this file could be just:

jobs:
  build:
    uses: ./.github/workflows/reusable_ci_workflow.yml
    with:
      PROJECT_PATH: ./src/HealthChecks.SqlServer/HealthChecks.SqlServer.csproj
      TEST_PROJECT_PATH: ./test/HealthChecks.SqlServer.Tests/HealthChecks.SqlServer.Tests.csproj
      CODECOV_FLAGS: SqlServer

(I took the example from

jobs:
build:
uses: ./.github/workflows/reusable_ci_workflow.yml
with:
PROJECT_PATH: ./src/HealthChecks.CosmosDb/HealthChecks.CosmosDb.csproj
TEST_PROJECT_PATH: ./test/HealthChecks.CosmosDb.Tests/HealthChecks.CosmosDb.Tests.csproj
CODECOV_FLAGS: CosmosDb
)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
github_actions Pull requests that update Github_actions code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants