Skip to content

Commit

Permalink
Use maxprocesses=2 for cli tests
Browse files Browse the repository at this point in the history
Co-authored-by: Eivind Jahren <[email protected]>
  • Loading branch information
2 people authored and sondreso committed Nov 1, 2024
1 parent 85eeb13 commit 2a5e828
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test_ert.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
- name: CLI Test
if: inputs.test-type == 'cli-tests'
run: |
pytest --cov=ert --cov-report=xml:cov1.xml --junit-xml=junit.xml -n logical -v --benchmark-disable --dist loadgroup tests/ui_tests/cli
pytest --cov=ert --cov-report=xml:cov1.xml --junit-xml=junit.xml -n logical --maxprocesses=2 -v --benchmark-disable --dist loadgroup tests/ui_tests/cli
- name: Unit Test
if: inputs.test-type == 'unit-tests'
Expand Down
13 changes: 6 additions & 7 deletions ci/testkomodo.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
copy_test_files () {
copy_test_files() {
cp -r ${CI_SOURCE_ROOT}/tests ${CI_TEST_ROOT}
ln -s ${CI_SOURCE_ROOT}/test-data ${CI_TEST_ROOT}/test-data

Expand All @@ -11,11 +11,11 @@ copy_test_files () {
ln -s ${CI_SOURCE_ROOT}/pyproject.toml ${CI_TEST_ROOT}/pyproject.toml
}

install_test_dependencies () {
install_test_dependencies() {
pip install ".[dev]"
}

run_ert_with_opm () {
run_ert_with_opm() {
pushd "${CI_TEST_ROOT}"

cp -r "${CI_SOURCE_ROOT}/test-data/flow_example" ert_with_opm
Expand All @@ -24,7 +24,7 @@ run_ert_with_opm () {
ert test_run flow.ert ||
(
# In case ert fails, print log files if they are there:
cat spe1_out/realization-0/iter-0/STATUS || true
cat spe1_out/realization-0/iter-0/STATUS || true
cat spe1_out/realization-0/iter-0/ERROR || true
cat spe1_out/realization-0/iter-0/FLOW.stderr.0 || true
cat spe1_out/realization-0/iter-0/FLOW.stdout.0 || true
Expand All @@ -33,15 +33,15 @@ run_ert_with_opm () {
popd
}

start_tests () {
start_tests() {
export NO_PROXY=localhost,127.0.0.1

export ECL_SKIP_SIGNAL=ON

pushd ${CI_TEST_ROOT}/tests

# Run all ert tests except tests evaluating memory consumption and tests requiring windows manager (GUI tests)
pytest --eclipse-simulator -n logical --show-capture=stderr -v --max-worker-restart 0 \
pytest --eclipse-simulator -n auto --show-capture=stderr -v --max-worker-restart 0 \
-m "not limit_memory and not requires_window_manager" --benchmark-disable --dist loadgroup
return_code_ert_main_tests=$?

Expand Down Expand Up @@ -72,7 +72,6 @@ start_tests () {

set -e


return_code_combined_tests=0
# We error if one or more returncodes are nonzero
if [ "$return_code_ert_main_tests" -ne 0 ]; then
Expand Down

0 comments on commit 2a5e828

Please sign in to comment.