extend the test files
Author: ydshieh
Pull request: yes

# What does this PR do?

Extend the test files in cross test CI job.

In #21023, flax bigbird modeling file is changed and the flax test file skips the pt/flax tests. However, the test fetcher is not designed to take into account the corresponding pytorch test file, and we have test failure in `main` on `nightly` run.

This PR extends the test files for `torch_and_tf` and `torch_and_flax` jobs to avoid such situation.

The effect could be seen in this run

https://app.circleci.com/pipelines/github/huggingface/transformers/63246/workflows/84722f3a-1259-4226-973d-267c74ca9aee/jobs/780372

Comments:
_The documentation is not available anymore as the PR was closed or merged._

I need to check if the new test files exist before adding them to the list. Will update later 

> I have already given my thoughts a thousand times on how such failures should be fixed, but since I'm being ignored again...

@sgugger I don't mean to ignore your suggestion, but the only discussion I remembered is [this slack discussion](https://huggingface.slack.com/archives/C01NE71C4F7/p1678714056980159?thread_ts=1678480555.678359&cid=C01NE71C4F7), where you mentioned (to my previous messages) with

> Mmmm, maybe there is a post-processing function that could do that yes. (Note that the whole thing for the pipeline will disappear with the new test fecther and the new way pipeline tests are designed).

Therefore I assume the approach in this PR (current version) is fine.

I might forget anything you mentioned earlier somewhere else. In this case, please share the link, and I am happy to take a look your suggestion. Otherwise, feel free to drop what you think the best. Thank you.

> This is not my preferred solution, but if we go for this, I'd like the added tests to be logged somewhere, so we can inspect the results. Otherwise we can't debug if there is a failure of the test fetcher, as the generated config is not exactly readable.

If we keep this approach, I am happy to save files of these modified version.



Note that I am not really in favor of duplicating the tests. We have these tests both in PT/TF or PT/Flax test files. It's already kind of duplication. And if we copy each version to another framework again, that is duplication of duplication.

Let's go with logging the modified test files somehow, so we can inspect the result of the code you add then.

Looks like it didn't touch any new file though.

> Looks like it didn't touch any new file though.

Yeah, I am bad at getting the correct path. Now it works (if I triggered the test via a change in a file), see 

https://app.circleci.com/pipelines/github/huggingface/transformers/63288/workflows/721ab3d6-b1af-4f2d-b036-9bebbdaef2cc/jobs/780955

@sgugger Could you check the last commit and see if it is OK? ~~(I will run a test to make sure everything works as expected tomorrow before merge, already tired today with some personal meetings)~~.

See [the new run page](https://app.circleci.com/pipelines/github/huggingface/transformers/63300/workflows/6cedeb02-795b-489f-8894-f5320ec64dd1/jobs/781128) and [here](https://app.circleci.com/pipelines/github/huggingface/transformers/63300/workflows/351a027d-9393-4c7d-a128-61cef5786f30/jobs/781146)

One thing to note is that, I put everything regarding cross tests into a single file as well as in the cross test jobs. So `test_modeling_tf_xxx.py` might be in the `tests_torch_and_flax` job and vice versa in some cases. It doesn't really matter as we correctly install the only necessary libraries in the job.