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

CODE REVIEW: Tests not working/ failing #29

Open
Psydwinder opened this issue Jan 18, 2023 · 1 comment
Open

CODE REVIEW: Tests not working/ failing #29

Psydwinder opened this issue Jan 18, 2023 · 1 comment

Comments

@Psydwinder
Copy link

Psydwinder commented Jan 18, 2023

Hey everyone,

Although there are multiple tests present in the 1.test.js file when the command node --test is run only one of the tests is checked and run... even then the test fails 😱

It might be worth splitting the tests up over multiple different js files so that they can be run indivdually with the npm run test:# command as well as the node --test command.

It might also be worth looking into your package.json file and amending the script for running a test as currently it isn't running one.

@lisahns
Copy link

lisahns commented Jan 18, 2023

it might also be worth to add a proper script, so that it is easier to run the tests, at the moment it looks like this
"test": "echo \"Error: no test specified\" && exit 1",
whereas you'd want something like this, especially if you split the tests into separate files:
"test": "node --no-warnings --test",
"test:1": "node --no-warnings test/1.test.js"
"test:2": "node --no-warnings test/2.test.js"
etc.
This will make it easier for you to read the test output

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants