vexflow
vexflow copied to clipboard
How to test for notes/elements?
I want to write tests for my app, but I'm not sure how to verify things.
For example, I want to write an E2E test (using Cypress) to verify that my app is producing staves with the correct clef/notes.
Browser inspection reveals the vf-stavenote element, but I don't see a way to test its pitch value so I know I haven't drawn a 'c4' when I expected something else. Same for clef and other elements.
I've considered visual regression testing, but this isn't always a good solution. For example, a random generator with a wide range of acceptable notes/elements would be troublesome.
Please advise!