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

Add Unit-Tests for core features #61

Open
stefan-balke opened this issue Nov 6, 2023 · 4 comments
Open

Add Unit-Tests for core features #61

stefan-balke opened this issue Nov 6, 2023 · 4 comments

Comments

@stefan-balke
Copy link

Unit-Tests are currently missing. You could start with testing core functionalities such as importing MusicXML files and checking against an expected MEI-output. These also give devs a good starting point to understand the inner functionalities of your software.

Derived from the JOSS review in openjournals/joss-reviews#6002 (comment)

@wergo
Copy link
Member

wergo commented Nov 10, 2023

@stefan-balke, we have started with this, but not elaborated carefully. We have used the Selenium framework for this. Would you have an alternative suggestion for this?

@stefan-balke
Copy link
Author

Hi @wergo,

for testing interaction and GUI elements, Selenium is one way to do it.
My suggestion aims more at the fundamental level which is easier to test, e.g., load an MXML file and make sure the MEI is what you expect, or save parameters and get what you expected it to save...or set or delete, not necessarily through user interaction. Could also be a call in a script you wrote.

@wergo
Copy link
Member

wergo commented Apr 16, 2024

Hi @stefan-balke thank you for your suggestion regarding testing. We have now implemented comprehensive end-to-end tests using PlayWright. Currently, there are 44 individual tests covereing different aspects of the application relating to editing, input, page load, facsimile display and editing, MIDI playback, application settings, UI translation, and URL parameters. These cover the major functionalities of mei-friend.

We will continue developing further tests to cover edge cases and new features as they come along. We are also still working making the existing tests more robust, as some of them can currently exhibit flaky behavior (run well on one occasion, but not on another).

Independently of these end-to-end tests, mei-friend also is able to run internal tests when deployed in the development environment. Currently we use this to validate the completeness of the language packs.

@stefan-balke
Copy link
Author

Hi @wergo,

as far as I understand it, playwrights tests on the JS components. How about the Python side of things? Is there anything that should be tested regularly? There should be some endpoints which take only certain types (or should take) etc.

Best,
Stefan

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