We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
[BUG] check_estimator tests_to_exclude doesn't exclude the specified tests
**Describe the bug**
<!--
A clear and concise description of what the bug is.
-->
Specifying a list of tests in the `tests_to_exclude` variable in `check_estimator` doesn't exclude the specified tests.

**To Reproduce**
<!--
Add a Minimal, Complete, and Verifiable example (for more details, see e.g. https://stackoverflow.com/help/mcve

If the code is too long, feel free to put it in a public gist and link it in the issue: https://gist.github.com
-->

```python
from sktime.utils.estimator_checks import check_estimator
from sktime.forecasting.naive import NaiveForecaster

log = check_estimator(
    NaiveForecaster, return_exceptions=True, tests_to_exclude=["test_predict_residuals"]
)

should_be_empty = [key for key in log.keys() if "test_predict_residuals" in key]

assert len(should_be_empty) == 0
```

**Expected behavior**
<!--
A clear and concise description of what you expected to happen.
-->
Any tests in the tests_to_excluded should be actually excluded!
(FYI for whoever takes this on. The problem is somewhere [here](https://github.com/sktime/sktime/blob/fe6f43c2e06e586c2dd16102aef5eef4bd4b6ce6/sktime/tests/test_all_estimators.py#L378))

**Versions**
<details>

<!--
Please run the following code snippet and paste the output here:
 
from sktime import show_versions; show_versions()
-->
sktime==0.13.4  
python==3.8.5
</details>  

<!-- Thanks for contributing! -->


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `sktime/utils/estimator_checks.py`
Content:
```
1 # -*- coding: utf-8 -*-
2 """Estimator checker for extension."""
3 
4 __author__ = ["fkiraly"]
5 __all__ = ["check_estimator"]
6 
7 from inspect import isclass
8 
9 
10 def check_estimator(
11     estimator,
12     return_exceptions=True,
13     tests_to_run=None,
14     fixtures_to_run=None,
15     verbose=True,
16     tests_to_exclude=None,
17     fixtures_to_exclude=None,
18 ):
19     """Run all tests on one single estimator.
20 
21     Tests that are run on estimator:
22         all tests in test_all_estimators
23         all interface compatibility tests from the module of estimator's scitype
24             for example, test_all_forecasters if estimator is a forecaster
25 
26     Parameters
27     ----------
28     estimator : estimator class or estimator instance
29     return_exception : bool, optional, default=True
30         whether to return exceptions/failures, or raise them
31             if True: returns exceptions in results
32             if False: raises exceptions as they occur
33     tests_to_run : str or list of str, optional. Default = run all tests.
34         Names (test/function name string) of tests to run.
35         sub-sets tests that are run to the tests given here.
36     fixtures_to_run : str or list of str, optional. Default = run all tests.
37         pytest test-fixture combination codes, which test-fixture combinations to run.
38         sub-sets tests and fixtures to run to the list given here.
39         If both tests_to_run and fixtures_to_run are provided, runs the *union*,
40         i.e., all test-fixture combinations for tests in tests_to_run,
41             plus all test-fixture combinations in fixtures_to_run.
42     verbose : str, optional, default=True.
43         whether to print out informative summary of tests run.
44     tests_to_exclude : str or list of str, names of tests to exclude. default = None
45         removes tests that should not be run, after subsetting via tests_to_run.
46     fixtures_to_exclude : str or list of str, fixtures to exclude. default = None
47         removes test-fixture combinations that should not be run.
48         This is done after subsetting via fixtures_to_run.
49 
50     Returns
51     -------
52     results : dict of results of the tests in self
53         keys are test/fixture strings, identical as in pytest, e.g., test[fixture]
54         entries are the string "PASSED" if the test passed,
55             or the exception raised if the test did not pass
56         returned only if all tests pass, or return_exceptions=True
57 
58     Raises
59     ------
60     if return_exception=False, raises any exception produced by the tests directly
61 
62     Examples
63     --------
64     >>> from sktime.forecasting.theta import ThetaForecaster
65     >>> from sktime.utils.estimator_checks import check_estimator
66     >>> results = check_estimator(ThetaForecaster, tests_to_run="test_pred_int_tag")
67     All tests PASSED!
68     >>> check_estimator(
69     ...    ThetaForecaster, fixtures_to_run="test_score[ThetaForecaster-y:1cols-fh=1]"
70     ... )
71     All tests PASSED!
72     {'test_score[ThetaForecaster-y:1cols-fh=1]': 'PASSED'}
73     """
74     from sktime.base import BaseEstimator
75     from sktime.classification.early_classification.tests.test_all_early_classifiers import (  # noqa E501
76         TestAllEarlyClassifiers,
77     )
78     from sktime.classification.tests.test_all_classifiers import TestAllClassifiers
79     from sktime.dists_kernels.tests.test_all_dist_kernels import (
80         TestAllPairwiseTransformers,
81         TestAllPanelTransformers,
82     )
83     from sktime.forecasting.tests.test_all_forecasters import TestAllForecasters
84     from sktime.registry import scitype
85     from sktime.regression.tests.test_all_regressors import TestAllRegressors
86     from sktime.tests.test_all_estimators import TestAllEstimators, TestAllObjects
87     from sktime.transformations.tests.test_all_transformers import TestAllTransformers
88 
89     testclass_dict = dict()
90     testclass_dict["classifier"] = TestAllClassifiers
91     testclass_dict["early_classifier"] = TestAllEarlyClassifiers
92     testclass_dict["forecaster"] = TestAllForecasters
93     testclass_dict["regressor"] = TestAllRegressors
94     testclass_dict["transformer"] = TestAllTransformers
95     testclass_dict["transformer-pairwise"] = TestAllPairwiseTransformers
96     testclass_dict["transformer-pairwise-panel"] = TestAllPanelTransformers
97 
98     results = TestAllObjects().run_tests(
99         estimator=estimator,
100         return_exceptions=return_exceptions,
101         tests_to_run=tests_to_run,
102         fixtures_to_run=fixtures_to_run,
103         tests_to_exclude=tests_to_exclude,
104         fixtures_to_exclude=fixtures_to_exclude,
105     )
106 
107     def is_estimator(obj):
108         """Return whether obj is an estimator class or estimator object."""
109         if isclass(obj):
110             return issubclass(obj, BaseEstimator)
111         else:
112             return isinstance(obj, BaseEstimator)
113 
114     if is_estimator(estimator):
115         results_estimator = TestAllEstimators().run_tests(
116             estimator=estimator,
117             return_exceptions=return_exceptions,
118             tests_to_run=tests_to_run,
119             fixtures_to_run=fixtures_to_run,
120             tests_to_exclude=tests_to_exclude,
121             fixtures_to_exclude=fixtures_to_exclude,
122         )
123         results.update(results_estimator)
124 
125     try:
126         scitype_of_estimator = scitype(estimator)
127     except Exception:
128         scitype_of_estimator = ""
129 
130     if scitype_of_estimator in testclass_dict.keys():
131         results_scitype = testclass_dict[scitype_of_estimator]().run_tests(
132             estimator=estimator,
133             return_exceptions=return_exceptions,
134             tests_to_run=tests_to_run,
135             fixtures_to_run=fixtures_to_run,
136         )
137         results.update(results_scitype)
138 
139     failed_tests = [key for key in results.keys() if results[key] != "PASSED"]
140     if len(failed_tests) > 0:
141         msg = failed_tests
142         msg = ["FAILED: " + x for x in msg]
143         msg = "\n".join(msg)
144     else:
145         msg = "All tests PASSED!"
146 
147     if verbose:
148         # printing is an intended feature, for console usage and interactive debugging
149         print(msg)  # noqa T001
150 
151     return results
152
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/sktime/utils/estimator_checks.py b/sktime/utils/estimator_checks.py
--- a/sktime/utils/estimator_checks.py
+++ b/sktime/utils/estimator_checks.py
@@ -133,6 +133,8 @@
             return_exceptions=return_exceptions,
             tests_to_run=tests_to_run,
             fixtures_to_run=fixtures_to_run,
+            tests_to_exclude=tests_to_exclude,
+            fixtures_to_exclude=fixtures_to_exclude,
         )
         results.update(results_scitype)

{"golden_diff": "diff --git a/sktime/utils/estimator_checks.py b/sktime/utils/estimator_checks.py\n--- a/sktime/utils/estimator_checks.py\n+++ b/sktime/utils/estimator_checks.py\n@@ -133,6 +133,8 @@\n             return_exceptions=return_exceptions,\n             tests_to_run=tests_to_run,\n             fixtures_to_run=fixtures_to_run,\n+            tests_to_exclude=tests_to_exclude,\n+            fixtures_to_exclude=fixtures_to_exclude,\n         )\n         results.update(results_scitype)\n", "issue": "[BUG] check_estimator tests_to_exclude doesn't exclude the specified tests\n**Describe the bug**\r\n<!--\r\nA clear and concise description of what the bug is.\r\n-->\r\nSpecifying a list of tests in the `tests_to_exclude` variable in `check_estimator` doesn't exclude the specified tests.\r\n\r\n**To Reproduce**\r\n<!--\r\nAdd a Minimal, Complete, and Verifiable example (for more details, see e.g. https://stackoverflow.com/help/mcve\r\n\r\nIf the code is too long, feel free to put it in a public gist and link it in the issue: https://gist.github.com\r\n-->\r\n\r\n```python\r\nfrom sktime.utils.estimator_checks import check_estimator\r\nfrom sktime.forecasting.naive import NaiveForecaster\r\n\r\nlog = check_estimator(\r\n    NaiveForecaster, return_exceptions=True, tests_to_exclude=[\"test_predict_residuals\"]\r\n)\r\n\r\nshould_be_empty = [key for key in log.keys() if \"test_predict_residuals\" in key]\r\n\r\nassert len(should_be_empty) == 0\r\n```\r\n\r\n**Expected behavior**\r\n<!--\r\nA clear and concise description of what you expected to happen.\r\n-->\r\nAny tests in the tests_to_excluded should be actually excluded!\r\n(FYI for whoever takes this on. The problem is somewhere [here](https://github.com/sktime/sktime/blob/fe6f43c2e06e586c2dd16102aef5eef4bd4b6ce6/sktime/tests/test_all_estimators.py#L378))\r\n\r\n**Versions**\r\n<details>\r\n\r\n<!--\r\nPlease run the following code snippet and paste the output here:\r\n \r\nfrom sktime import show_versions; show_versions()\r\n-->\r\nsktime==0.13.4  \r\npython==3.8.5\r\n</details>  \r\n\r\n<!-- Thanks for contributing! -->\r\n\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\n\"\"\"Estimator checker for extension.\"\"\"\n\n__author__ = [\"fkiraly\"]\n__all__ = [\"check_estimator\"]\n\nfrom inspect import isclass\n\n\ndef check_estimator(\n    estimator,\n    return_exceptions=True,\n    tests_to_run=None,\n    fixtures_to_run=None,\n    verbose=True,\n    tests_to_exclude=None,\n    fixtures_to_exclude=None,\n):\n    \"\"\"Run all tests on one single estimator.\n\n    Tests that are run on estimator:\n        all tests in test_all_estimators\n        all interface compatibility tests from the module of estimator's scitype\n            for example, test_all_forecasters if estimator is a forecaster\n\n    Parameters\n    ----------\n    estimator : estimator class or estimator instance\n    return_exception : bool, optional, default=True\n        whether to return exceptions/failures, or raise them\n            if True: returns exceptions in results\n            if False: raises exceptions as they occur\n    tests_to_run : str or list of str, optional. Default = run all tests.\n        Names (test/function name string) of tests to run.\n        sub-sets tests that are run to the tests given here.\n    fixtures_to_run : str or list of str, optional. Default = run all tests.\n        pytest test-fixture combination codes, which test-fixture combinations to run.\n        sub-sets tests and fixtures to run to the list given here.\n        If both tests_to_run and fixtures_to_run are provided, runs the *union*,\n        i.e., all test-fixture combinations for tests in tests_to_run,\n            plus all test-fixture combinations in fixtures_to_run.\n    verbose : str, optional, default=True.\n        whether to print out informative summary of tests run.\n    tests_to_exclude : str or list of str, names of tests to exclude. default = None\n        removes tests that should not be run, after subsetting via tests_to_run.\n    fixtures_to_exclude : str or list of str, fixtures to exclude. default = None\n        removes test-fixture combinations that should not be run.\n        This is done after subsetting via fixtures_to_run.\n\n    Returns\n    -------\n    results : dict of results of the tests in self\n        keys are test/fixture strings, identical as in pytest, e.g., test[fixture]\n        entries are the string \"PASSED\" if the test passed,\n            or the exception raised if the test did not pass\n        returned only if all tests pass, or return_exceptions=True\n\n    Raises\n    ------\n    if return_exception=False, raises any exception produced by the tests directly\n\n    Examples\n    --------\n    >>> from sktime.forecasting.theta import ThetaForecaster\n    >>> from sktime.utils.estimator_checks import check_estimator\n    >>> results = check_estimator(ThetaForecaster, tests_to_run=\"test_pred_int_tag\")\n    All tests PASSED!\n    >>> check_estimator(\n    ...    ThetaForecaster, fixtures_to_run=\"test_score[ThetaForecaster-y:1cols-fh=1]\"\n    ... )\n    All tests PASSED!\n    {'test_score[ThetaForecaster-y:1cols-fh=1]': 'PASSED'}\n    \"\"\"\n    from sktime.base import BaseEstimator\n    from sktime.classification.early_classification.tests.test_all_early_classifiers import (  # noqa E501\n        TestAllEarlyClassifiers,\n    )\n    from sktime.classification.tests.test_all_classifiers import TestAllClassifiers\n    from sktime.dists_kernels.tests.test_all_dist_kernels import (\n        TestAllPairwiseTransformers,\n        TestAllPanelTransformers,\n    )\n    from sktime.forecasting.tests.test_all_forecasters import TestAllForecasters\n    from sktime.registry import scitype\n    from sktime.regression.tests.test_all_regressors import TestAllRegressors\n    from sktime.tests.test_all_estimators import TestAllEstimators, TestAllObjects\n    from sktime.transformations.tests.test_all_transformers import TestAllTransformers\n\n    testclass_dict = dict()\n    testclass_dict[\"classifier\"] = TestAllClassifiers\n    testclass_dict[\"early_classifier\"] = TestAllEarlyClassifiers\n    testclass_dict[\"forecaster\"] = TestAllForecasters\n    testclass_dict[\"regressor\"] = TestAllRegressors\n    testclass_dict[\"transformer\"] = TestAllTransformers\n    testclass_dict[\"transformer-pairwise\"] = TestAllPairwiseTransformers\n    testclass_dict[\"transformer-pairwise-panel\"] = TestAllPanelTransformers\n\n    results = TestAllObjects().run_tests(\n        estimator=estimator,\n        return_exceptions=return_exceptions,\n        tests_to_run=tests_to_run,\n        fixtures_to_run=fixtures_to_run,\n        tests_to_exclude=tests_to_exclude,\n        fixtures_to_exclude=fixtures_to_exclude,\n    )\n\n    def is_estimator(obj):\n        \"\"\"Return whether obj is an estimator class or estimator object.\"\"\"\n        if isclass(obj):\n            return issubclass(obj, BaseEstimator)\n        else:\n            return isinstance(obj, BaseEstimator)\n\n    if is_estimator(estimator):\n        results_estimator = TestAllEstimators().run_tests(\n            estimator=estimator,\n            return_exceptions=return_exceptions,\n            tests_to_run=tests_to_run,\n            fixtures_to_run=fixtures_to_run,\n            tests_to_exclude=tests_to_exclude,\n            fixtures_to_exclude=fixtures_to_exclude,\n        )\n        results.update(results_estimator)\n\n    try:\n        scitype_of_estimator = scitype(estimator)\n    except Exception:\n        scitype_of_estimator = \"\"\n\n    if scitype_of_estimator in testclass_dict.keys():\n        results_scitype = testclass_dict[scitype_of_estimator]().run_tests(\n            estimator=estimator,\n            return_exceptions=return_exceptions,\n            tests_to_run=tests_to_run,\n            fixtures_to_run=fixtures_to_run,\n        )\n        results.update(results_scitype)\n\n    failed_tests = [key for key in results.keys() if results[key] != \"PASSED\"]\n    if len(failed_tests) > 0:\n        msg = failed_tests\n        msg = [\"FAILED: \" + x for x in msg]\n        msg = \"\\n\".join(msg)\n    else:\n        msg = \"All tests PASSED!\"\n\n    if verbose:\n        # printing is an intended feature, for console usage and interactive debugging\n        print(msg)  # noqa T001\n\n    return results\n", "path": "sktime/utils/estimator_checks.py"}], "after_files": [{"content": "# -*- coding: utf-8 -*-\n\"\"\"Estimator checker for extension.\"\"\"\n\n__author__ = [\"fkiraly\"]\n__all__ = [\"check_estimator\"]\n\nfrom inspect import isclass\n\n\ndef check_estimator(\n    estimator,\n    return_exceptions=True,\n    tests_to_run=None,\n    fixtures_to_run=None,\n    verbose=True,\n    tests_to_exclude=None,\n    fixtures_to_exclude=None,\n):\n    \"\"\"Run all tests on one single estimator.\n\n    Tests that are run on estimator:\n        all tests in test_all_estimators\n        all interface compatibility tests from the module of estimator's scitype\n            for example, test_all_forecasters if estimator is a forecaster\n\n    Parameters\n    ----------\n    estimator : estimator class or estimator instance\n    return_exception : bool, optional, default=True\n        whether to return exceptions/failures, or raise them\n            if True: returns exceptions in results\n            if False: raises exceptions as they occur\n    tests_to_run : str or list of str, optional. Default = run all tests.\n        Names (test/function name string) of tests to run.\n        sub-sets tests that are run to the tests given here.\n    fixtures_to_run : str or list of str, optional. Default = run all tests.\n        pytest test-fixture combination codes, which test-fixture combinations to run.\n        sub-sets tests and fixtures to run to the list given here.\n        If both tests_to_run and fixtures_to_run are provided, runs the *union*,\n        i.e., all test-fixture combinations for tests in tests_to_run,\n            plus all test-fixture combinations in fixtures_to_run.\n    verbose : str, optional, default=True.\n        whether to print out informative summary of tests run.\n    tests_to_exclude : str or list of str, names of tests to exclude. default = None\n        removes tests that should not be run, after subsetting via tests_to_run.\n    fixtures_to_exclude : str or list of str, fixtures to exclude. default = None\n        removes test-fixture combinations that should not be run.\n        This is done after subsetting via fixtures_to_run.\n\n    Returns\n    -------\n    results : dict of results of the tests in self\n        keys are test/fixture strings, identical as in pytest, e.g., test[fixture]\n        entries are the string \"PASSED\" if the test passed,\n            or the exception raised if the test did not pass\n        returned only if all tests pass, or return_exceptions=True\n\n    Raises\n    ------\n    if return_exception=False, raises any exception produced by the tests directly\n\n    Examples\n    --------\n    >>> from sktime.forecasting.theta import ThetaForecaster\n    >>> from sktime.utils.estimator_checks import check_estimator\n    >>> results = check_estimator(ThetaForecaster, tests_to_run=\"test_pred_int_tag\")\n    All tests PASSED!\n    >>> check_estimator(\n    ...    ThetaForecaster, fixtures_to_run=\"test_score[ThetaForecaster-y:1cols-fh=1]\"\n    ... )\n    All tests PASSED!\n    {'test_score[ThetaForecaster-y:1cols-fh=1]': 'PASSED'}\n    \"\"\"\n    from sktime.base import BaseEstimator\n    from sktime.classification.early_classification.tests.test_all_early_classifiers import (  # noqa E501\n        TestAllEarlyClassifiers,\n    )\n    from sktime.classification.tests.test_all_classifiers import TestAllClassifiers\n    from sktime.dists_kernels.tests.test_all_dist_kernels import (\n        TestAllPairwiseTransformers,\n        TestAllPanelTransformers,\n    )\n    from sktime.forecasting.tests.test_all_forecasters import TestAllForecasters\n    from sktime.registry import scitype\n    from sktime.regression.tests.test_all_regressors import TestAllRegressors\n    from sktime.tests.test_all_estimators import TestAllEstimators, TestAllObjects\n    from sktime.transformations.tests.test_all_transformers import TestAllTransformers\n\n    testclass_dict = dict()\n    testclass_dict[\"classifier\"] = TestAllClassifiers\n    testclass_dict[\"early_classifier\"] = TestAllEarlyClassifiers\n    testclass_dict[\"forecaster\"] = TestAllForecasters\n    testclass_dict[\"regressor\"] = TestAllRegressors\n    testclass_dict[\"transformer\"] = TestAllTransformers\n    testclass_dict[\"transformer-pairwise\"] = TestAllPairwiseTransformers\n    testclass_dict[\"transformer-pairwise-panel\"] = TestAllPanelTransformers\n\n    results = TestAllObjects().run_tests(\n        estimator=estimator,\n        return_exceptions=return_exceptions,\n        tests_to_run=tests_to_run,\n        fixtures_to_run=fixtures_to_run,\n        tests_to_exclude=tests_to_exclude,\n        fixtures_to_exclude=fixtures_to_exclude,\n    )\n\n    def is_estimator(obj):\n        \"\"\"Return whether obj is an estimator class or estimator object.\"\"\"\n        if isclass(obj):\n            return issubclass(obj, BaseEstimator)\n        else:\n            return isinstance(obj, BaseEstimator)\n\n    if is_estimator(estimator):\n        results_estimator = TestAllEstimators().run_tests(\n            estimator=estimator,\n            return_exceptions=return_exceptions,\n            tests_to_run=tests_to_run,\n            fixtures_to_run=fixtures_to_run,\n            tests_to_exclude=tests_to_exclude,\n            fixtures_to_exclude=fixtures_to_exclude,\n        )\n        results.update(results_estimator)\n\n    try:\n        scitype_of_estimator = scitype(estimator)\n    except Exception:\n        scitype_of_estimator = \"\"\n\n    if scitype_of_estimator in testclass_dict.keys():\n        results_scitype = testclass_dict[scitype_of_estimator]().run_tests(\n            estimator=estimator,\n            return_exceptions=return_exceptions,\n            tests_to_run=tests_to_run,\n            fixtures_to_run=fixtures_to_run,\n            tests_to_exclude=tests_to_exclude,\n            fixtures_to_exclude=fixtures_to_exclude,\n        )\n        results.update(results_scitype)\n\n    failed_tests = [key for key in results.keys() if results[key] != \"PASSED\"]\n    if len(failed_tests) > 0:\n        msg = failed_tests\n        msg = [\"FAILED: \" + x for x in msg]\n        msg = \"\\n\".join(msg)\n    else:\n        msg = \"All tests PASSED!\"\n\n    if verbose:\n        # printing is an intended feature, for console usage and interactive debugging\n        print(msg)  # noqa T001\n\n    return results\n", "path": "sktime/utils/estimator_checks.py"}]}