Dolphin, the GameCube and Wii emulator - Forums

Full Version: Is additional unit test coverage welcome?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi all, I'm a GameCube fan and software engineer interested in dabbling with open-source contributions in my free time. While digging around the Dolphin repo, I noticed that there seem to be big chunks of the codebase not covered by unit tests. I thought it would be fun and educational to try to fill some of those coverage gaps. Is that something that would be welcomed by the developers? Or is the lack of unit test coverage intentional? (I'm not sure what the general approach to unit-testing in open-source projects is, and I know that having a bunch of unit test coverage does add a maintenance burden as code changes.)

If more unit test coverage is welcome, do you all have any particular style guidance or opinions? I think my current approach to writing unit tests generally matches this book's philosophy: https://abseil.io/resources/swe-book/html/ch12.html.

Also, one unrelated question while I'm here: my library of Wii and GameCube games is pretty small, and I have no plans to expand it. If I'm ever interested in contributing to Dolphin beyond adding unit tests, will that hold me back? I notice a lot of the bug reports are of the form "XYZ glitch in some random game", and I imagine that kind of bug report is hard to work on if you don't have access to the game in question.
The reason we don't have more unit testing is mostly that no one has had the time. Theoretically, we'd love to have more unit testing. However, whether or not will accept a unit test pull request depends heavily on that pull request itself - what the unit test is testing, and how it is written to accomplish it.

If you just want to write some unit tests and don't have specific goals in mind, ask us what unit tests we want! I'm sure you'll get a lot of responses.

Also this may be best asked in #dolphin-dev on libera or #dolphin-development on our discord. For a faster back and forth conversation.