add generic test functions for testing discrete univariate distributions