Add toggling in deprecation setting tests