Skip to content

Commit

Permalink
Make ConfigValueError test more specific
Browse files Browse the repository at this point in the history
  • Loading branch information
Jasha10 committed Nov 5, 2023
1 parent 95fcc64 commit aa9a970
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions tests/test_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
is_union_annotation,
split_key,
)
from omegaconf.errors import UnsupportedValueType, ValidationError
from omegaconf.errors import ConfigValueError, UnsupportedValueType, ValidationError
from omegaconf.nodes import (
AnyNode,
BooleanNode,
Expand Down Expand Up @@ -407,7 +407,9 @@ def test_get_structured_config_data_illegal_value(test_cls: Any) -> None:

def test_get_structured_config_data_attrs_takes_self() -> None:
test_cls = _TestAttrsTakesSelf
with raises(ValueError):
with raises(
ConfigValueError, match="'takes_self' in attrs attributes is not supported"
):
_utils.get_structured_config_data(test_cls)


Expand Down

0 comments on commit aa9a970

Please sign in to comment.