MCPcopy Create free account
hub / github.com/dcos/dcos-cli / test_plugin_concurrent_invocation

Function test_plugin_concurrent_invocation

tests/integration/test_plugin.py:162–173  ·  view source on GitHub ↗
(default_cluster)

Source from the content-addressed store, hash-verified

160@pytest.mark.skipif(sys.platform == 'win32',
161 reason='Not yet concurrent-safe on Windows (DCOS_OSS-4843)')
162def test_plugin_concurrent_invocation(default_cluster):
163 _install_test_plugin()
164
165 with futures.ThreadPoolExecutor() as pool:
166 cmds = [pool.submit(exec_cmd, ['dcos', 'test', 'arg']) for _ in range(50)]
167
168 completed, _ = futures.wait(cmds, timeout=30)
169 assert len(completed) == 50
170
171 for cmd in completed:
172 code, out, err = cmd.result()
173 assert code == 0, out + err
174
175
176def test_plugin_verbosity(default_cluster):

Callers

nothing calls this directly

Calls 1

_install_test_pluginFunction · 0.85

Tested by

no test coverage detected