def METHOD_NAME(datatype, params):
    X, y = fetch_california_housing(return_X_y=True)
    X = X.astype(datatype)
    y = y.astype(datatype)
    culars = cuLars(**params)
    culars.fit(X, y)
    sklars = skLars(**params)
    sklars.fit(X, y)
    assert culars.score(X, y) >= sklars.score(X, y) - 0.01
    limit_max_iter = "n_nonzero_coefs" in params
    if limit_max_iter:
        n_iter_tol = 0
    else:
        n_iter_tol = 2
    assert abs(culars.n_iter_ - sklars.n_iter_) <= n_iter_tol
    tol = 1e-4 if params.pop("fit_intercept", True) else 1e-1
    n = min(culars.n_iter_, sklars.n_iter_)
    assert array_equal(
        culars.alphas_[:n], sklars.alphas_[:n], unit_tol=tol, total_tol=1e-4
    )
    assert array_equal(culars.active_[:n], sklars.active_[:n])
    if limit_max_iter:
        assert array_equal(culars.coef_, sklars.coef_)
        if hasattr(sklars, "coef_path_"):
            assert array_equal(
                culars.coef_path_,
                sklars.coef_path_[sklars.active_],
                unit_tol=1e-3,
            )
        intercept_diff = abs(culars.intercept_ - sklars.intercept_)
        if abs(sklars.intercept_) > 1e-6:
            intercept_diff /= sklars.intercept_
            assert intercept_diff <= 1e-3