I think that a function whose assert fires is not working properly and is not ready for testing at all. Besides, there are not so many cases when you should keep asserts in your production code.