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

test: Rework Pipeline.run() tests to ease declaration with dataclasses #7790

Merged
merged 4 commits into from
Jun 3, 2024

Conversation

silvanocerza
Copy link
Contributor

Related Issues

Proposed Changes:

Add a new PipelineRunData dataclass that holds all the information necessary to run a Pipeline and verify its correct execution. This dataclass will be returned by the functions marked with @given together with the Pipeline instance to run.

I also added a _PipelineResult dataclass used in the boilerplate code that runs and verifies the Pipeline.run() execution.

How did you test it?

I ran tests locally.

Notes for the reviewer

I also changes slightly the tests for the "bad" Pipeline runs as they were unnecesssarily returning the expected Exception class too. This made it simpler to structure the PipelineRunData dataclass.

Checklist

@silvanocerza silvanocerza added the ignore-for-release-notes PRs with this flag won't be included in the release notes. label Jun 3, 2024
@silvanocerza silvanocerza requested a review from shadeMe June 3, 2024 12:38
@silvanocerza silvanocerza self-assigned this Jun 3, 2024
@silvanocerza silvanocerza requested review from a team as code owners June 3, 2024 12:38
@silvanocerza silvanocerza requested review from dfokina and anakin87 and removed request for a team, dfokina and anakin87 June 3, 2024 12:38
@coveralls
Copy link
Collaborator

Pull Request Test Coverage Report for Build 9350724425

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 89.75%

Totals Coverage Status
Change from base Build 9348644629: 0.0%
Covered Lines: 6690
Relevant Lines: 7454

💛 - Coveralls

@silvanocerza silvanocerza merged commit 74df8ed into main Jun 3, 2024
21 checks passed
@silvanocerza silvanocerza deleted the pipeline-run-test-dataclass branch June 3, 2024 13:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ignore-for-release-notes PRs with this flag won't be included in the release notes. topic:tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants