Bring back the PR `Refactor doctests + add CI` to `main`
Reverts huggingface/transformers#23245

So we can keep the PR #22987 regarding the new doctest way, but without exposing `doctest_utils` to `src/transformers`.

@sgugger Let me know if you prefer to move this `doctest_utils.py` to `tests` folder.
> Can you put the new testing utils (from `doctest_utils`) in `testing_utils`, so it all goes in the same place?

In this case, am I allowed to put the import of `pytest` and `_pytest` on the top level of `testing_utils`? I am asking because I see in that file there is

```python
        try:
            import pytest  # We don't need a hard dependency on pytest in the main library
        except ImportError:
            return test_case
```
<|||||>There is no direct import into `testing_utils.py` so this should be fine to remove the try except (we will have until next release to make sure it doesn't create a new core dep of Transformers :sweat_smile: )<|||||>The docs for this PR live [here](https://moon-ci-docs.huggingface.co/docs/transformers/pr_23271). All of your documentation changes will be reflected on that endpoint.<|||||>Thanks for taking care of this! Think the filtered list could be obtain in a cleaner way with some bash commands but otherwise great 👍🏻 <|||||>@ArthurZucker It was finally going to a `tests_fetcher.py`

https://github.com/huggingface/transformers/pull/23277/files

The bash command was just getting too complex ...<|||||>Nice! Thanks for following up