Skip to content

Commit 79ff37a

Browse files
correct test eigenpro and huber
1 parent 9abcf67 commit 79ff37a

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

sklearn_extra/kernel_methods/tests/test_eigenpro.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def gen_classification(params):
3131
@pytest.mark.parametrize(
3232
"params, err_msg",
3333
[
34-
({"kernel": "not_a_kernel"}, "Unknown kernel 'not_a_kernel'"),
34+
({"kernel": "not_a_kernel"}, "The 'metric' parameter of pairwise_kernels must be a str among {'cosine', 'poly', 'laplacian', 'polynomial', 'chi2', 'linear', 'sigmoid', 'additive_chi2', 'precomputed', 'rbf'} or a callable. Got 'not_a_kernel' instead."),
3535
({"n_epoch": 0}, "n_epoch should be positive, was 0"),
3636
({"n_epoch": -1}, "n_epoch should be positive, was -1"),
3737
({"n_components": -1}, "n_components should be non-negative, was -1"),

sklearn_extra/robust/tests/test_mean_estimators.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ def test_mom():
2727

2828
def test_huber():
2929
X = np.hstack([np.zeros(90), np.ones(10)])
30-
with pytest.warns(None) as record:
31-
mu = huber(X, c=0.5)
30+
mu = huber(X, c=0.5)
3231
assert len(record) == 0
3332
assert np.abs(mu) < 0.1

0 commit comments

Comments
 (0)