I see you found a good solution (I think it's nice for all of us that you document your problem solving ) , but wanted to mention this challenge was mentioned in an R-hub blog post.
- Solution involving mocking How can I make testthat think I don't have a package installed?
- Solution without mocking, involving different continuous integration builds where at least one doesn't install the Suggested package. https://blog.r-hub.io/2019/10/29/mocking/#different-system-configurations-or-libraries