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

Run tests as separate jobs #813

Merged
merged 13 commits into from
May 1, 2024

Conversation

nkaretnikov
Copy link
Contributor

@nkaretnikov nkaretnikov commented Apr 18, 2024

Description

This pull request:

  • splits up tests into multiple workflows
  • splits up integration tests into multiple jobs
  • fixes some flaky tests.

Pull request checklist

  • Did you test this change locally?
  • Did you update the documentation (if required)?
  • Did you add/update relevant tests for this change (if required)?

Additional information

  • Now, if integration tests fail, you don't need to wait for unit tests to finish before restarting them, and vice versa.
  • Integration tests are split into multiple jobs, so it's easier to restart each separately (there's less chance of a job failing because it involves less tests now).

Also see #803.

How to test

Copy link

netlify bot commented Apr 18, 2024

Deploy Preview for conda-store canceled.

Name Link
🔨 Latest commit e8159cb
🔍 Latest deploy log https://app.netlify.com/sites/conda-store/deploys/663189452f9a990008d97c75

@nkaretnikov nkaretnikov mentioned this pull request Apr 21, 2024
7 tasks
@nkaretnikov nkaretnikov changed the title Run integration tests as separate jobs Run tests as separate jobs Apr 21, 2024
@nkaretnikov nkaretnikov marked this pull request as ready for review April 21, 2024 09:34
Copy link
Contributor

@peytondmurray peytondmurray left a comment

Choose a reason for hiding this comment

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

Just a few comments, otherwise this looks like it will really help the CI be more useful. Thanks for this 🚀

Copy link
Collaborator

Choose a reason for hiding this comment

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

We should perhaps rename it to build_docker.yaml as it is not testing the Docker image per se

@@ -0,0 +1,62 @@
name: "Test build Docker image"
Copy link
Collaborator

Choose a reason for hiding this comment

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

Suggested change
name: "Test build Docker image"
name: "Build and push Docker image"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Had a similar idea as well, but decided against it to avoid confusion. We already have a job called build_and_push_docker_image that's part of release.yaml. This job was part of tests.yaml, so I prefixed it with "Test" to see which is which. AFAICT, it also doesn't push anything because of push: false, so looks like the intention here is to just test whether a docker container can be built.

In the interest of time, I'm going to merge this as is since it's already approved, but this can always be resolved in followup PRs.

Copy link
Collaborator

Choose a reason for hiding this comment

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

But it is not testing the docker image just building it the fact that we have a step/job named build and push is inconsequential to having a workflow named build or build and push.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, I think a better name might be "Build Docker image", but we already have a file called build_docker_image.yaml with the name "Publish Dev Docker Images".

I think my preferred solution would be making all these consistent, so that the name matches the filename and there are no clashes between files. Something like this (untested):

  • "Publish dev Docker image" -> publish_dev_docker_image.yaml (renamed from "Publish Dev Docker Images")
  • "Build Docker image" -> build_docker_image.yaml (the workflow discussed in this thread)

@peytondmurray Hey Peyton, I'm currently on PTO, would you be comfortable taking over this in a separate PR? The task would be coming up with a consistent scheme for names and filenames of docker workflows.

@nkaretnikov nkaretnikov merged commit 6b486f3 into conda-incubator:main May 1, 2024
27 checks passed
peytondmurray pushed a commit to peytondmurray/conda-store that referenced this pull request May 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: Done 💪🏾
Development

Successfully merging this pull request may close these issues.

3 participants