Skip to content

Running multiple test files #755

Description

@scossu

I am organizing tests for my application in multiple files, that should be run in a specific sequence. I started by ordering the test file names alphabetically, but that is becoming unsustainable quickly; plus, I need to add some scaffolding functions that should be used by multiple
test. For that reason, I thought about having a master test file to do all the configuration and call individual test files in a sequence.

I tried several methods involving dofile and adding require "busted.runner"() to the master file, but even if I make the required module global, Lua cannot recognize the Bused keywords (describe, pending, etc).

If I put the Busted requirement in the individual files, the executable runs only the first test file and then exits.

Is there a way to achieve this setup?

Thanks.

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