Refactor reflection tests and reflection source test.