Skip to content

lint:bats-test-task should recognize test/_default namespace tasks #76

Description

@brownie-ricon

Problem

codebase lint:bats-test-task only recognizes the file-task form:

.mise/tasks/test

It does not recognize the namespace default-task form:

.mise/tasks/test/_default

Mise treats that _default file as the implementation for mise run test, and this shape is needed when a repo also wants nested test tasks such as mise run test:python.

Concrete case

In KnickKnackLabs/permissions#2, the repo has:

.mise/tasks/test/_default  # canonical BATS runner for `mise run test`
.mise/tasks/test/python    # Python unit tests, invoked as `mise run test:python`

mise run test works and BATS passes, but codebase lint:bats-test-task reports:

OK    permissions (no .mise/tasks/test — nothing to check)

That is misleading because there is a BATS test task, just in namespace _default form.

Expected behavior

The lint should inspect .mise/tasks/test/_default when .mise/tasks/test is a directory and apply the same canonical BATS task checks to that file.

If both forms somehow exist or the directory has no _default, it should report an actionable result consistent with mise behavior.

Why it matters

Without this, repos that use conventional nested tasks such as test:python, test:unit, or test:integration lose the BATS task lint coverage while still appearing green.

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