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

Adding all WDL unit tests to API pytests #102

Open
wants to merge 16 commits into
base: main
Choose a base branch
from
Open

Conversation

tefirman
Copy link
Collaborator

@tefirman tefirman commented Feb 6, 2025

Description

  • Expanding test-failures.py to include all unit test WDLs to the cromwellapi pytests
  • Creating an analogous test-successes.py to check for success from all non-bad unit test WDLs

Related Issues

Testing

  • Updated pytests worked great locally using the Makefile.
  • Pushed the new vcr cassettes to this PR.

@tefirman tefirman requested review from sckott and seankross February 6, 2025 05:51
@tefirman
Copy link
Collaborator Author

tefirman commented Feb 6, 2025

@sckott, really hope I didn't duplicate efforts, I should've checked with you first, sorry about that. Mind taking a look?

@sckott
Copy link
Collaborator

sckott commented Feb 6, 2025

Will do in the morning

Copy link
Collaborator

@sckott sckott left a comment

Choose a reason for hiding this comment

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

Nice, looks good!

There's some formatting that could be done, but doesn't need to be done here, opened an issue to add a new gh action workflow #104

tests/cromwellapi/test-successes.py Outdated Show resolved Hide resolved
tests/cromwellapi/test-successes.py Outdated Show resolved Hide resolved
@tefirman
Copy link
Collaborator Author

tefirman commented Feb 6, 2025

Thanks @sckott ! Removing those unused packages, and great call on the new issue with linting/formatting actions, seems like a smart step.

@tefirman
Copy link
Collaborator Author

tefirman commented Feb 6, 2025

Now that I look back at test-call.py compared to test-failures.py and test-successes.py, I'm wondering if there's too much overlap, essentially submitting the same jobs twice but checking for slightly different things each time.. Should we think about consolidating those? Or is it better to have the redundancy just in case?

@sckott
Copy link
Collaborator

sckott commented Feb 6, 2025

@tefirman

I'm wondering if there's too much overlap, essentially submitting the same jobs twice but checking for slightly different things each time

But I don't think we are

In conftest.py we submit the jobs. In most of the tests, including the ones worked on and referenced here, we just ping the cromwell api to get metadata on the already submitted jobs.

there are a few tests where we submit workflows but i think those are hopefully cases where we need to to do the correct test

@tefirman
Copy link
Collaborator Author

tefirman commented Feb 7, 2025

Ahhh, you're totally right @sckott , didn't fully grasp that. So we may have duplicate API metadata calls (which is fine), but the actual workflows only run once during conftest.py, correct?

@sckott
Copy link
Collaborator

sckott commented Feb 7, 2025

the actual workflows only run once during conftest.py, correct?

yes

@tefirman tefirman added the infrastructure Infrastructure fix to execute WDL GitHub Actions label Feb 11, 2025
@tefirman tefirman linked an issue Feb 11, 2025 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
infrastructure Infrastructure fix to execute WDL GitHub Actions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Checking Outputs in Pytest vs. Assertions within WDL "Bad" and "good" WDLs in API tests
2 participants