Spaces:
Sleeping
Sleeping
| import pytest | |
| from baseline import create_baseline_pipeline, fix_commas, _remove_punctuation | |
| def baseline_pipeline(): | |
| yield create_baseline_pipeline() | |
| def test_fix_commas_leaves_correct_strings_unchanged(baseline_pipeline, test_input): | |
| result = fix_commas(baseline_pipeline, s=test_input) | |
| assert result == test_input | |
| def test_fix_commas_fixes_incorrect_commas(baseline_pipeline, test_input, expected): | |
| result = fix_commas(baseline_pipeline, s=test_input) | |
| assert result == expected | |
| def test__remove_punctuation(test_input, expected): | |
| assert _remove_punctuation(test_input) == expected | |