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

Tests are failing, while npm run test #5373

Open
2 tasks done
pacostas opened this issue Mar 26, 2024 · 3 comments
Open
2 tasks done

Tests are failing, while npm run test #5373

pacostas opened this issue Mar 26, 2024 · 3 comments

Comments

@pacostas
Copy link

pacostas commented Mar 26, 2024

Prerequisites

  • I have written a descriptive issue title
  • I have searched existing issues to ensure the issue has not already been raised

Issue

Steps to reproduce

OS on virtual machine:
Linux fedora 6.7.4-200.fc39.x86_64

Node version:
20.11.1

Steps:

  1. git clone https://github.com/fastify/fastify.git
  2. cd fastify
  3. npm i
  4. npm run test

Gives below 2 errors:

  • error 1
 FAIL ​ test/async-await.test.js 81 OK 1s
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/async-await.test.js
  exitCode: null
  signal: SIGTERM

 FAIL ​ TAP
 ✖ test/async-await.test.js

  test: TAP
  env: {}
  file: test/async-await.test.js
  timeout: 30000
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/async-await.test.js
  stdio:
    - 0
    - pipe
    - 2
  cwd: /home/costas/Desktop/fastify
  exitCode: null
  signal: SIGTERM

 FAIL ​ test/hooks.on-listen.test.js 165 OK 523.559ms
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/hooks.on-listen.test.js
  exitCode: null
  signal: SIGTERM

 FAIL ​ TAP
 ✖ test/hooks.on-listen.test.js

  test: TAP
  env: {}
  file: test/hooks.on-listen.test.js
  timeout: 30000
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/hooks.on-listen.test.js
  stdio:
    - 0
    - pipe
    - 2
  cwd: /home/costas/Desktop/fastify
  exitCode: null
  signal: SIGTERM

 FAIL ​ test/internals/reply.test.js 346 OK 2s
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/internals/reply.test.js
  exitCode: null
  signal: SIGTERM

 FAIL ​ TAP
 ✖ test/internals/reply.test.js

  test: TAP
  env: {}
  file: test/internals/reply.test.js
  timeout: 30000
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/internals/reply.test.js
  stdio:
    - 0
    - pipe
    - 2
  cwd: /home/costas/Desktop/fastify
  exitCode: null
  signal: SIGTERM

  • error 2
 FAIL ​ test/hooks.on-listen.test.js 165 OK 523.559ms
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/hooks.on-listen.test.js
  exitCode: null
  signal: SIGTERM

 FAIL ​ test/internals/reply.test.js 346 OK 2s
  command: /home/costas/.nvm/versions/node/v20.11.1/bin/node
  args:
    - --allow-natives-syntax
    - test/internals/reply.test.js
  exitCode: null
  signal: SIGTERM

@pacostas pacostas changed the title 1 test is failing while npm run test Tests are failing, while npm run test Mar 26, 2024
@gurgunday
Copy link
Member

gurgunday commented Mar 26, 2024

Things seem fine on MacOS, could be dependent on your environment or maybe Linux, but CI looks OK too...

@pacostas
Copy link
Author

pacostas commented Mar 26, 2024

Thanks for trying that out on MacOS. The issue seems to be on Fedora and probably on linux in general I'm also able to reproduce it in ubuntu with docker.

FROM ubuntu:22.04
WORKDIR /app

RUN apt-get update && apt-get install -y curl

RUN curl -fsSL https://deb.nodesource.com/setup_20.x | bash - && apt-get install -y nodejs git

RUN git clone https://github.com/fastify/fastify.git && cd fastify && npm i && npm run test

The error on the descirption of the issue is produced from a clean virtual machine with fedora without tweaking any of the configuration. Do you know if i need any specific configuration for the tests to pass? I also see that it fails on citgm too https://ci.nodejs.org/view/Node.js-citgm/job/citgm-smoker/3404/nodes=alpine-last-latest-x64/testReport/junit/(root)/citgm/fastify_v4_26_2/

@climba03003
Copy link
Member

climba03003 commented Mar 27, 2024

The reference on CITGM is irrelevant, it fails because it cannot connect to the address, the error EADDRNOTAVAIL is unrelated to fastify.

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

3 participants