Skip to content

Expose fixture and test functions to allow to use them dynamically #1373

Closed
@reaktivo

Description

Are you requesting a feature or reporting a bug?

Requesting a feature

What is the current behavior?

For TestCafe to run a test we have to create a file which explicitly calls the fixture() and the test() function at least once.

What is the expected behavior?

Ideally we should be able to grab a handle of this functions without requiring to create a test file, this would allow us to integrate TestCafe with other test tools. I'm currently struggling to integrate with CucumberJS. Being able to have a reference to the fixture() and test() global functions would allow me to use the CucumberJS hooks which would help in transitioning to TestCafe without losing a lot of feature files that have been written with the Gherkin syntax.

How would you reproduce the current behavior (if this is a bug)?

N/A

Is there any others wishing to integrate TestCafe with other test tools? I'm currently working on a hacky solutions which involves generating test files at test execution time, requiring my actual test files and passing the fixture and test functions as reference (still not working thought). And I would like to know if there's any blessed way of doing this cleanly in a supported way.

Activity

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

    STATE: StaleAn outdated issue that will be automatically closed by the Stale bot.SYSTEM: APISYSTEM: compilerTYPE: enhancementThe accepted proposal for future implementation.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions