Skip to content

missing extensions are not ignored by default #329

Description

@lucascolley

array-api-tests/README.md

Lines 174 to 179 in 606cc4d

#### Extensions
By default, tests for the optional Array API extensions such as
[`linalg`](https://data-apis.org/array-api/latest/extensions/linear_algebra_functions.html)
will be skipped if not present in the specified array module. You can purposely
skip testing extension(s) via the `--disable-extension` option.

seems false. See https://github.com/mdhaber/marray/actions/runs/12521857195/job/34929420471?pr=47, which runs pytest -v -rxXfE --ci --max-examples=100 --derandomize --disable-deadline array_api_tests/

Activity

  1. lucascolley commented on Dec 28, 2024

    @lucascolley
    MemberAuthor

    perhaps

    if category in EXTENSIONS:
    ext_mod = getattr(xp, category)
    assert hasattr(ext_mod, name), f"{xp.__name__} is missing the {category} extension function {name}()"

    should be using enabled_extensions from here

    disabled_extensions = config.getoption("--disable-extension")
    enabled_extensions = sorted({
    ext for ext in EXTENSIONS + ['fft'] if ext not in disabled_extensions and xp_has_ext(ext)
    })

  2. lucascolley commented on Dec 28, 2024

    @lucascolley
    MemberAuthor

    it seems that test_has_names doesn't take --disable-extension into account when it is set either.

  3. ev-br commented on Jan 1, 2025

    @ev-br
    Member

    PR most welcome!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions