Skip to content

Commit

Permalink
TEST
Browse files Browse the repository at this point in the history
  • Loading branch information
wjsi committed Jun 28, 2022
1 parent b4d582f commit c85d140
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion ci/reload-env.sh
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/bash

export UNAME="$(uname | awk '{print tolower($0)}')"
export PYTEST_CONFIG_WITHOUT_COV="--log-level=DEBUG --timeout=1500 -W ignore::PendingDeprecationWarning"
export PYTEST_CONFIG_WITHOUT_COV="-p no:logging -s --timeout=1500 -W ignore::PendingDeprecationWarning"
export PYTEST_CONFIG="$PYTEST_CONFIG_WITHOUT_COV --cov-config=setup.cfg --cov-report= --cov=mars"

if [[ "$GITHUB_REF" =~ ^"refs/tags/" ]]; then
Expand Down
2 changes: 1 addition & 1 deletion ci/run-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ if [ -z "$NO_COMMON_TESTS" ]; then
pytest $PYTEST_CONFIG mars/remote mars/storage mars/lib mars/metrics
mv .coverage build/.coverage.tileable.file

pytest $PYTEST_CONFIG --forked --ignore mars/tensor --ignore mars/dataframe \
pytest $PYTEST_CONFIG --forked -v --ignore mars/tensor --ignore mars/dataframe \
--ignore mars/learn --ignore mars/remote mars
mv .coverage build/.coverage.main.file
coverage combine build/ && coverage report
Expand Down
12 changes: 11 additions & 1 deletion mars/tests/test_cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,19 @@ def _terminate(pid: int):
continue


@pytest.fixture
def config_log():
import logging
logging.basicConfig(level=logging.WARNING)
try:
yield
finally:
logging.basicConfig(level=logging.DEBUG)


@flaky(max_runs=3)
@pytest.mark.asyncio
async def test_cluster():
async def test_cluster(config_log):
port = get_next_port()
web_port = get_next_port()
supervisor_addr = f"127.0.0.1:{port}"
Expand Down

0 comments on commit c85d140

Please sign in to comment.