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

Implement system testing #164

Closed
meator opened this issue May 28, 2024 · 3 comments
Closed

Implement system testing #164

meator opened this issue May 28, 2024 · 3 comments
Milestone

Comments

@meator
Copy link
Collaborator

meator commented May 28, 2024

Some parts of the codebase (mainly src/main.cc) can't be effectively tested with Catch2 (src/main.cc includes the program entrypoint). System testing can be used to extend the tests. Another solution would be to put parts of the logic from main.cc somewhere else, but system testing provides many additional advantages which justify it being implemented in j4-dmenu-desktop.

I have considered using the atf-sh framework from kyua.

This feature won't be a part of the upcoming r3.0 release.

@meator
Copy link
Collaborator Author

meator commented May 29, 2024

https://github.com/bats-core/bats-core looks nice. It's available on all major distros (to my knowledge).

@meator meator added this to the r3.1 milestone Jun 7, 2024
@meator
Copy link
Collaborator Author

meator commented Jun 24, 2024

Bats tests are currently implemented in develop. I might still change my mind about this and revert the relevant commits. The testing system is figured out, but more tests will have to be added.

Bats tests are optional. They will be marked as skipped if bats tests cannot be executed.

@meator meator closed this as completed Jun 24, 2024
@meator meator reopened this Jul 26, 2024
@meator
Copy link
Collaborator Author

meator commented Jul 26, 2024

I believe that the choice to use Bats was not appropriate. This issue will require more consideration.

meator added a commit that referenced this issue Jul 29, 2024
I believe that this change will contribute to the usefulness and
maintainability of system tests.

The current implementation still has room for improvement. I will try
to refactor things when necessary.

This commit replaces Bats with pytest and nothing else. The test data
and other stuff still references bats. These references will be fixed
in other commits.

related to #164
@meator meator closed this as completed Jul 31, 2024
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

1 participant