Not trying to specifically shill my own library, but I developed this a while ago before there were any established patterns with filtering on relationships in graphql.
https://github.com/tandg-digital/objection-filter
Out of curiosity, would functionality like this implemented in graphql solve your issues?
I completely agree. If you have limited time to write tests, then I've found that integration tests provide the most value by far. If you're happy with your suite of integration tests, then it's also great to have a set of unit tests.
Out of curiosity, would functionality like this implemented in graphql solve your issues?