I am about to deprecate a function from a CRAN package. This function has a number of unit tests implemented.
The lege artis way of deprecating a function seems to be including
.Deprecated("use XYZ instead") call when the function is called.
This seems reasonable, but it triggers a warning in the unit tests - and I am sort of uncomfortable with submitting to CRAN a package known to fail in tests, but on the other hand I do not wish to remove the tests in question altogether (there is a reason I have them in place).
Is there a way out of this conundrum? I am certain I am not the first person facing this...