Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

An error appears when test starts without defined fixture #2913

Closed
AlexKamaev opened this issue Oct 1, 2018 · 3 comments
Closed

An error appears when test starts without defined fixture #2913

AlexKamaev opened this issue Oct 1, 2018 · 3 comments
Assignees
Labels
AREA: server STATE: Auto-locked An issue has been automatically locked by the Lock bot. SYSTEM: runner TYPE: bug The described behavior is considered as wrong (bug).
Milestone

Comments

@AlexKamaev
Copy link
Contributor

I missed fixture keyword and got
TypeError: Cannot read property 'requestHooks' of null at new requestHooks (D:\projects\testcafe\src\api\structure\test.js:16:42)

@AlexKamaev AlexKamaev added TYPE: bug The described behavior is considered as wrong (bug). SYSTEM: runner AREA: server labels Oct 1, 2018
@AlexKamaev AlexKamaev added this to the Planned milestone Oct 1, 2018
@miherlosev miherlosev modified the milestones: Planned, Sprint #19 Oct 1, 2018
@miherlosev miherlosev self-assigned this Oct 1, 2018
@miherlosev
Copy link
Collaborator

The problem reproduces when the fixture directive is commented.

// fixture `Fixture`;

test('test', async t => {});

Parser does not takes into account that directive is commented.
Need to fix for both test and fixture directives.

@AndreyBelym
Copy link
Contributor

AndreyBelym commented Oct 2, 2018

Please take into account that we are about to remove checking for fixture and test in test files: #2074 is in the current sprint's milestone.

IMHO it's better to check in the test 's constuctor that there is a defined fixture.

@AndreyBelym AndreyBelym modified the milestones: Sprint #19, Sprint #20 Oct 15, 2018
@AndreyBelym AndreyBelym modified the milestones: Sprint #20, Sprint #21 Oct 31, 2018
@AlexKamaev AlexKamaev assigned AlexKamaev and unassigned miherlosev Oct 31, 2018
AlexKamaev added a commit to AlexKamaev/testcafe that referenced this issue Nov 12, 2018
@lock
Copy link

lock bot commented Mar 28, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs or feature requests. For TestCafe API, usage and configuration inquiries, we recommend asking them on StackOverflow.

@lock lock bot added the STATE: Auto-locked An issue has been automatically locked by the Lock bot. label Mar 28, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Mar 28, 2019
kirovboris pushed a commit to kirovboris/testcafe-phoenix that referenced this issue Dec 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
AREA: server STATE: Auto-locked An issue has been automatically locked by the Lock bot. SYSTEM: runner TYPE: bug The described behavior is considered as wrong (bug).
Projects
None yet
Development

No branches or pull requests

3 participants