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

Fix code coverage #10

Open
douglaskastle opened this issue Mar 23, 2020 · 2 comments
Open

Fix code coverage #10

douglaskastle opened this issue Mar 23, 2020 · 2 comments

Comments

@douglaskastle
Copy link
Member

Code cover in this project is slightly irrelevant. Consider removing.

When this code is being used to enable addon testing, it is the addon that needs the code coverage, not anything from here.

It's presence here might be confusing.

It should definitely be in the new form blender-fake-addon.

Thought?

@myselfhimself
Copy link
Collaborator

myselfhimself commented Mar 24, 2020

I had disabled code coverage from the entry point function.
It can be enabled from the input config dictionary.

The entry point function is this one:
https://github.com/douglaskastle/blender-addon-tester/blob/c6e5499d68ce8fe0faf7a96e8a7853b9ecf83176/blender_addon_tester/__init__.py#L4

An example of enabled coverage through a config dict toggling parameter is here:
https://github.com/douglaskastle/blender-addon-tester/blob/c6e5499d68ce8fe0faf7a96e8a7853b9ecf83176/examples/testing-fake-addon/test_fake_addon_blender_advanced.py#L13

I have always favored creativity over test coverage perfection. Putting coverage tests on any project is new to me. I will not encourage or discourage that. :)

@douglaskastle
Copy link
Member Author

You are mostly right about coverage, when it is your own code. When you try and write tests for code you didn't write, coverage is invaluable. It gives you a lot of guidance and areas of testing you are missing.

I know TDD mandates that all tests should be written before the code is written. In my world the code exists already and the tests usually come in months later.

Any way the mandate here is to enable the act, not do the act. (though I may add coverage to all the code in this repo)

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

No branches or pull requests

2 participants