Refactor signal tests.