1919# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
2020# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
2121# SOFTWARE.
22+ """Module for multiple plugins test."""
2223
2324from dataclasses import dataclass
2425
3839
3940@dataclass
4041class MockConfigA1 :
42+ """Mock config."""
43+
4144 field_a1 : int
4245
4346
4447class MockLauncherA1 (interface .LauncherProtocol [MockConfigA1 ]):
48+ """Mock launcher."""
49+
4550 CONFIG_MODEL = MockConfigA1
4651
4752
4853@dataclass
4954class MockConfigA2 :
55+ """Mock config."""
56+
5057 field_a2 : int
5158
5259
5360class MockLauncherA2 (interface .LauncherProtocol [MockConfigA2 ]):
61+ """Mock launcher."""
62+
5463 CONFIG_MODEL = MockConfigA2
5564
5665
5766@dataclass
5867class MockConfigB1 :
68+ """Mock config."""
69+
5970 field_b1 : int
6071
6172
6273class MockLauncherB1 (interface .LauncherProtocol [MockConfigB1 ]):
74+ """Mock launcher for testing CLI configuration for product B."""
75+
6376 CONFIG_MODEL = MockConfigB1
6477
6578
@@ -74,10 +87,12 @@ class MockLauncherB1(interface.LauncherProtocol[MockConfigB1]):
7487
7588@pytest .fixture (autouse = True )
7689def monkeypatch_entrypoints (monkeypatch_entrypoints_from_plugins ):
90+ """Mock entrypoints for the plugins."""
7791 monkeypatch_entrypoints_from_plugins (PLUGINS )
7892
7993
8094def test_cli_structure ():
95+ """Test CLI structure."""
8196 command = _cli .build_cli (_plugins .get_all_plugins ())
8297 assert "configure" in command .commands
8398 configure_group = command .commands ["configure" ]
@@ -93,6 +108,7 @@ def test_cli_structure():
93108
94109
95110def test_configure_single_product_launcher (temp_config_file ):
111+ """Test configuring a single product with a single launcher."""
96112 cli_command = _cli .build_cli (_plugins .get_all_plugins ())
97113 runner = CliRunner ()
98114 result = runner .invoke (
@@ -113,6 +129,7 @@ def test_configure_single_product_launcher(temp_config_file):
113129
114130
115131def test_configure_two_product_launchers (temp_config_file ):
132+ """Test configuring two different products with different launch modes."""
116133 cli_command = _cli .build_cli (_plugins .get_all_plugins ())
117134 runner = CliRunner ()
118135 result = runner .invoke (
@@ -141,6 +158,7 @@ def test_configure_two_product_launchers(temp_config_file):
141158
142159
143160def test_configure_two_product_launchers_overwrite (temp_config_file ):
161+ """Test configuring two products with overwriting configurations."""
144162 cli_command = _cli .build_cli (_plugins .get_all_plugins ())
145163 runner = CliRunner ()
146164 result = runner .invoke (
@@ -169,6 +187,7 @@ def test_configure_two_product_launchers_overwrite(temp_config_file):
169187
170188
171189def test_configure_two_products (temp_config_file ):
190+ """Test configuring two products."""
172191 cli_command = _cli .build_cli (_plugins .get_all_plugins ())
173192 runner = CliRunner ()
174193 result = runner .invoke (
0 commit comments