Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
mike0sv committed Feb 14, 2025
1 parent 63e040e commit fc84ab3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/evidently/future/metrics/column_statistics.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,8 @@ def __init__(
column: str,
categories: Optional[List[CategoryCountLabel]] = None,
category: Optional[CategoryCountLabel] = None,
tests: Optional[List[MetricTest]] = None,
share_tests: Optional[List[MetricTest]] = None,
):
categories = categories or []
if category is not None:
Expand All @@ -225,7 +227,7 @@ def __init__(
if len(categories) != len(set(categories)):
duplicated = [k for k, v in Counter(categories).items() if v > 1]
raise ValueError(f"Duplicate categories: [{', '.join(str(c) for c in duplicated)}]")
super().__init__(column=column, categories=categories)
super().__init__(column=column, categories=categories, tests=tests, share_tests=share_tests)

def _default_tests_with_reference(self, context: Context) -> List[BoundTest]:
return [
Expand Down

0 comments on commit fc84ab3

Please sign in to comment.