File tree Expand file tree Collapse file tree 1 file changed +9
-0
lines changed
airbyte_cdk/test/standard_tests Expand file tree Collapse file tree 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 4
4
from dataclasses import asdict
5
5
from typing import TYPE_CHECKING
6
6
7
+ import pytest
8
+
7
9
from airbyte_cdk .models import (
8
10
AirbyteMessage ,
9
11
AirbyteStream ,
@@ -59,6 +61,13 @@ def test_discover(
59
61
scenario : ConnectorTestScenario ,
60
62
) -> None :
61
63
"""Standard test for `discover`."""
64
+ if scenario .expected_outcome .expect_exception ():
65
+ # If the scenario expects an exception, we can't ensure it specifically would fail
66
+ # in discover, because some discover implementations do not need to make a connection.
67
+ # We skip this test in that case.
68
+ pytest .skip ("Skipping discover test for scenario that expects an exception." )
69
+ return
70
+
62
71
run_test_job (
63
72
self .create_connector (scenario ),
64
73
"discover" ,
You can’t perform that action at this time.
0 commit comments