Skip to content

test/parallel/test-dgram-connect.js fails locally #27341

Description

@joyeecheung
/Users/joyee/projects/node/test/parallel/test-dgram-connect.js:40
    assert.ok(err.code === 'ENOTFOUND' || err.code === 'EAI_AGAIN');
                  ^

TypeError: Cannot read property 'code' of undefined
    at Socket.<anonymous> (/Users/joyee/projects/node/test/parallel/test-dgram-connect.js:40:19)
    at Socket.<anonymous> (/Users/joyee/projects/node/test/common/index.js:373:15)
    at Object.onceWrapper (events.js:284:20)
    at Socket.emit (events.js:196:13)
    at dgram.js:418:31
    at processTicksAndRejections (internal/process/task_queues.js:81:9)

Does not reproduce if I turn my Wifi off (it's probably hijacking DNS requests to invalid domains), so I guess either this should be moved to internet instead, or we should mock the lookup.

Activity

  1. added
    testIssues and PRs related to Node.js core tests and test infrastructure.
    dgramIssues and PRs related to UDP and the dgram module.
    on Apr 22, 2019
  2. Trott commented on Apr 24, 2019

    @Trott
  3. Trott commented on Apr 24, 2019

    @Trott
  4. joyeecheung commented on May 2, 2019

    @joyeecheung
    MemberAuthor

    @Trott yeah, the issue is that the ISP may not be doing what it's supposed to do and it could e.g. hijack the invalid DNS request so that when you visit it in the browser it redirects you to a page full of their ads :/

  5. joyeecheung commented on May 2, 2019

    @joyeecheung
    MemberAuthor

    I guess the easiest solution is to move this test to test/internet because it sends out actual DNS requests.

  6. santigimeno commented on May 2, 2019

    @santigimeno
    Member

    I guess the easiest solution is to move this test to test/internet because it sends out actual DNS requests.

    I think this is fine, but I would just move that specific test not the whole file.

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

    dgramIssues and PRs related to UDP and the dgram module.good first issueIssues that are suitable for first-time contributors.testIssues and PRs related to Node.js core tests and test infrastructure.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions