Refactor Module tests