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 unittests for the app #18

Open
Demfier opened this issue Nov 23, 2017 · 6 comments
Open

Adding unittests for the app #18

Demfier opened this issue Nov 23, 2017 · 6 comments

Comments

@Demfier
Copy link
Collaborator

Demfier commented Nov 23, 2017

It would be really nice if we can add have testing framework.
For reference on testing framework for a django app, refer to the django-testing-docs.

@kurianbenoy
Copy link
Collaborator

@Demfier I was eager to work on this issue, what kind of test do you want?

@kurianbenoy
Copy link
Collaborator

I specifically meant it's all in order and working now, what do we want more to add Tests

To my best of knowledge, test is while developing in django and during application development only.So why do we need test otherwise?
Please share your thoughts at @Demfier

@Demfier
Copy link
Collaborator Author

Demfier commented Dec 15, 2017

@kurianbenoy - Glad to have someone interested in this issue 😄

Tests are crucial for any application. Whenever we add new code or modify an existing piece of code, how do you ensure that it is working as expected? For small changes, you can quickly run the app and check its behavior. But when the change is a substantial one (say you upgrade the entire application which can lead to deprecations and a lot of dead code), you can't simply run the app and check each and every unit of the app. You need to automate this stuff (we are in the 21st century for god's sake!) and hence, you write tests for them. Testing isn't just restricted to the development stage, it backs the software even after deployment.

Apart from the reason stated above, some other benefits of writing tests:

  1. You can deal with issues like backward-compatibility when you uptick your apps
  2. You get to use automated cloud testing pipelines like the various CIs available (I really like this one ❤️)

Hope I was able to tell you the importance of tests. You can use the docs link as mentioned in the very first description in case you still feel motivated to take up this task.
Let me know if you have any other query.

@kurianbenoy
Copy link
Collaborator

@Demfier - thank You for mentioning other uses of Tests 😃

I understood the 1st issue ie to test the problems like backward compatibily you mentioned (As like in case of shifting to Django 2.0 version most of things will show deprecation warnings )

I couldn't understand 2nd point

I will do a bit more research on Tests , (I used tests during development,ie all the experience I have 👐 )
I will inform you specifically before hopping into codebase

@kurianbenoy kurianbenoy self-assigned this Dec 21, 2017
@kurianbenoy
Copy link
Collaborator

kurianbenoy commented Dec 21, 2017

@Demfier I have added a module coverage to check the percent of tests in our repositary

Also I would like a clarification , whether this issue only applicable for unit test in module?

@Demfier
Copy link
Collaborator Author

Demfier commented Dec 21, 2017 via email

@kurianbenoy kurianbenoy reopened this Feb 3, 2018
@kurianbenoy kurianbenoy removed their assignment Jun 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants