Skip to content

Commit

Permalink
Avoid version specific sed syntax
Browse files Browse the repository at this point in the history
The argument to sed prior to this change triggers something in sed version 4.6 or 4.7

Also solve contamination issues that has crept in.
  • Loading branch information
berland committed Dec 13, 2024
1 parent 0ca408f commit 97d8363
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
15 changes: 9 additions & 6 deletions .github/workflows/test_ert.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,12 +66,6 @@ jobs:
run: |
pytest --cov=ert --cov=everest --cov=_ert --cov-report=xml:cov1.xml --junit-xml=junit.xml -o junit_family=legacy -n logical --show-capture=stderr -v --benchmark-disable --dist loadgroup tests/ert/performance_tests --durations=25
- name: Test for a clean repository
run: |
# Run this before the 'Test CLI' entry below, which produces a few files that are accepted for now. Exclude the wheel.
git status --porcelain | sed '/ert.*.whl$\|\/block_storage$/d'
test -z "$(git status --porcelain | sed '/ert.*.whl$\\|\\/block_storage$/d')"
- name: Upload coverage to Codecov
id: codecov1
uses: codecov/codecov-action@v4
Expand Down Expand Up @@ -109,3 +103,12 @@ jobs:
- name: Test CLI
run: |
ert --help
- name: Test for a clean repository
run: |
# Remove things we have generated on purpose:
rm -rf .coverage
rm -f coverage.xml cov1.xml cov2.xml junit.xml
rm -f ert.*.whl
git status --porcelain
test -z "$(git status --porcelain)"
2 changes: 2 additions & 0 deletions tests/ert/unit_tests/config/test_num_cpu.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ def test_default_num_cpu():
assert ert_config.preferred_num_cpu == 1


@pytest.mark.usefixtures("use_tmpdir")
def test_num_cpu_from_config_preferred():
data_file = "dfile"
config_num_cpu = 17
Expand Down Expand Up @@ -77,6 +78,7 @@ def test_reading_num_cpu_from_binary_data_file_does_not_crash(data_file_contents
"", # Not valid input in some reservoir simulators
],
)
@pytest.mark.usefixtures("use_tmpdir")
def test_num_cpu_from_data_file_used_if_config_num_cpu_not_set(
parallelsuffix, casetitle
):
Expand Down

0 comments on commit 97d8363

Please sign in to comment.