better unit tests for numeric_to_factor