Add tests for check_prefixes function.