Skip to content

Commit

Permalink
tests: xfail experiments-related flakey tests
Browse files Browse the repository at this point in the history
  • Loading branch information
skshetry committed Jan 6, 2023
1 parent bfb6a32 commit 3dfdd57
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
14 changes: 14 additions & 0 deletions tests/func/experiments/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import json

import pytest

pytestmark = pytest.mark.xfail(
raises=(
# looks like dvc-task is not saving json atomically
json.JSONDecodeError,
# needs investigation, maybe a file locking issue?
PermissionError,
),
strict=False,
reason="See https://github.com/iterative/dvc/issues/8570",
)
10 changes: 10 additions & 0 deletions tests/func/experiments/test_experiments.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
import stat
from textwrap import dedent

import dulwich.errors
import dulwich.file
import pytest
from funcy import first

Expand Down Expand Up @@ -137,6 +139,14 @@ def test_apply(tmp_dir, scm, dvc, exp_stage):
assert (tmp_dir / "metrics.yaml").read_text().strip() == "foo: 3"


@pytest.mark.xfail(
raises=(
dulwich.errors.CommitError,
dulwich.file.FileLocked,
),
strict=False,
reason="See https://github.com/iterative/dvc/issues/8570",
)
def test_apply_failed(tmp_dir, scm, dvc, failed_exp_stage, test_queue):
from dvc.exceptions import InvalidArgumentError

Expand Down

0 comments on commit 3dfdd57

Please sign in to comment.