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

[BLOCKING] Clone optimade-python-tools and run docker-compose #3

Merged
merged 2 commits into from
Mar 12, 2020

Conversation

CasperWA
Copy link
Member

Fixes #2

The initial work-around here is to git clone the optimade-python-repository into the temporary GH Actions server and - without installing anything - run the docker-compose.yml file found in the repository root of optimade-python-repository.

@CasperWA CasperWA requested review from ml-evs and shyamd March 11, 2020 16:54
@CasperWA CasperWA changed the title Clone optimade-python-tools and run docker-compose [BLOCKING] Clone optimade-python-tools and run docker-compose Mar 11, 2020
@shyamd
Copy link

shyamd commented Mar 12, 2020

So, the CI tests might be ill-conditioned here. The CI shouldn't be testing the optimade-server but the action. Since the action tests the optimade-server, we don't actually want to test the server in the CI. Rather we should just be testing to ensure the action is running the right command and properly failing/succeeding depending on the output of that command.

@CasperWA
Copy link
Member Author

CasperWA commented Mar 12, 2020

So, the CI tests might be ill-conditioned here. The CI shouldn't be testing the optimade-server but the action. Since the action tests the optimade-server, we don't actually want to test the server in the CI. Rather we should just be testing to ensure the action is running the right command and properly failing/succeeding depending on the output of that command.

Agreed. It's a bit wishy-washy where to draw the line at the moment though. But I have been introducing tests of entrypoint.sh via BATS in #4. Maybe that's more sensible in the end? Although I do think we should also have at least the two first tests from the CI or something similar to it to test that the optimade_validator will indeed be invoked correctly.

Edit: Right, so thinking more about this, I indeed wanted to run this action passing a URL as well, however, there wasn't anyone working I could come up with. But I guess we could try Heroku? The validator doesn't appreciate the (valid) provider.optimade.org still.
Also, I think, to properly test the action, we should test it should be able to handle a "local" server as well? But maybe we can compromise and state that this is tested from the optimade-python-tools library?

@shyamd
Copy link

shyamd commented Mar 12, 2020

Yup. I like the BATS testing. One viable option would be to make a dummy optimade-validator in the right place and ensure it gets called.

@CasperWA
Copy link
Member Author

CasperWA commented Mar 12, 2020

Yup. I like the BATS testing. One viable option would be to make a dummy optimade-validator in the right place and ensure it gets called.

Very nice idea. It just sets an environment variable, outputs something or other, which can then be tested with BATS 👍

@CasperWA
Copy link
Member Author

So what do you say to get this merged as a temporary solution, opening the possibility of getting the other open PRs merged, create an issue to convert all CI to BATS testing (based on the work I started in #4) and then finally release v1 - the CI testing shouldn't hinder the release I think?

Copy link
Member

@ml-evs ml-evs left a comment

Choose a reason for hiding this comment

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

Missed the huge blocking sign when I reviewed the other PR first X)

@CasperWA
Copy link
Member Author

CasperWA commented Mar 12, 2020

Missed the huge blocking sign when I reviewed the other PR first X)

No worries - but what do you think about this comment?

Never mind, it seems all are on board 😄

@shyamd
Copy link

shyamd commented Mar 12, 2020

I agree, let's merge and then update.

@CasperWA CasperWA merged commit 35883b6 into Materials-Consortia:master Mar 12, 2020
@CasperWA CasperWA deleted the fix_2_CI-tests branch March 12, 2020 17:10
@CasperWA CasperWA mentioned this pull request Mar 12, 2020
12 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Fix CI tests
3 participants