Restore original task in test_warning_logs
# What does this PR do?

`test_warning_logs` modifies `PIPELINE_REGISTRY` via `PIPELINE_REGISTRY.register_pipeline(alias, {})`, which fails the tests in `TextClassificationPipelineTests`.

This PR restores the original task at the end of `test_warning_logs`.

cc @aarnphm
_The documentation is not available anymore as the PR was closed or merged._