digitalfondue / lavagna

Lavagna: issue tracker/project management tool
http://lavagna.io
GNU General Public License v3.0
635 stars 109 forks source link

Removed resource optimism (test smell) #141

Closed eas5 closed 3 years ago

eas5 commented 3 years ago

This is a test refactoring.

The resource optimism occurs when a test method makes an optimistic assumption that the external resource (e.g., File), utilized by the test method, exists.

As this test creates and copies files before using them, it is necessary to ensure that any problems in the setup steps will make the test execution be skipped instead of failing without adequately testing the import and export operations.

The separation of setup and teardown steps from the test method also increases the test readability.

coveralls commented 3 years ago

Coverage Status

Coverage remained the same at 65.417% when pulling 87880b392a7773d5c6f47e816fb4d58d89d650e5 on eas5:test_improvement into 6dfb2ab2f1e82698f0847562c030f1fb3248c205 on digitalfondue:master.

coveralls commented 3 years ago

Coverage Status

Coverage remained the same at 65.417% when pulling 87880b392a7773d5c6f47e816fb4d58d89d650e5 on eas5:test_improvement into 6dfb2ab2f1e82698f0847562c030f1fb3248c205 on digitalfondue:master.

syjer commented 3 years ago

thank you for the PR 👍