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

Tests Needs #27

Open
aligoren opened this issue Jun 10, 2019 · 10 comments
Open

Tests Needs #27

aligoren opened this issue Jun 10, 2019 · 10 comments
Labels

Comments

@aligoren
Copy link
Contributor

Hi.

I know there is not many contributors here.

But even like that, I think we should write tests.

Before then I think some modules should be rewritten. I know this isn’t easy.

Every developer in this project has its work like me.

Maybe we think a new structure with Flask or an async framework like Bocadillo.

Maybe we talk about the documentation in a different issue.

@Humbedooh
Copy link
Member

Tests would be awesome. I'm not sure where to start - perhaps with the server API? I know there have been some shortcuts made to speed up processes in the OpenAPI department, that should probably get fixed :) (such as response definitions left very open)

@aligoren
Copy link
Contributor Author

aligoren commented Jun 10, 2019

Hehe :) yes. I’ll read whole codebase to understand how it works.

Because there are also no docstrings.

I’ll try to find friends to make this project much betters.

@michalslowikowski00
Copy link
Contributor

Hey guys.
Maybe pre-commit will be a good idea to starts with?
I can do it, a least try to do it.
https://pre-commit.com/

@turbaszek
Copy link
Member

+1 for introducing pre-commit. It will allow us to assert code quality as a first step and then we can add tests that can also be run using this tool (+ pytest).

If someone is not familiar with this framework - it's a simple tool that allows users to share and install git hooks that are run before commit. In this way the code quality (and more) is checked even before making a contribution. Of course - it's not necessary but it helps a lot. We use this in Apache Airflow to automatically verify multiple things such as code style, language style (no black and white lists and so on) and formatting of documentation 👍

Probably it would be good to consider using some CI to avoid regression in the future. WDYT @Humbedooh @sharanf @michalslowikowski00 ?

@michalslowikowski00
Copy link
Contributor

@turbaszek yes, absolutely, +1 for the CI. I thought that the Circle CI is implemented here. But it is not.

@sharanf
Copy link
Contributor

sharanf commented Oct 6, 2020

@michalslowikowski00 thanks for the suggestion. And it sounds like a good practical idea - I like it. Let me check any other community feedback.

@michalslowikowski00
Copy link
Contributor

@sharanf should we introduce some proposals via the dev list?

@sharanf
Copy link
Contributor

sharanf commented Oct 6, 2020

@michalslowikowski00 yes for new stuff, it is best to see if others have an opinion and you will see that I have already started this discussion there :-)

@michalslowikowski00
Copy link
Contributor

I subscribed dev list. :)

@turbaszek
Copy link
Member

Ok, so we've got CI up and running. Now it's time to think about testing 😄

From discussions in #38 and #48 it seems that it would be wise to rethink the backend of API (+1 for using a framework as @aligoren suggested). But before we decide on something I think it would be a good step to add test coverage for existing API so we are sure that the UI will still work.

Currently, there's 61 API endpoints defined in openapi spec, each can be used with ~2 methods, so we need about 120 test. That's is not that much if we make those test generic and easy to write.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

5 participants