GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — test: skip test-process-config if no config.gypi by gibfahn · Pull Request #16436 · nodejs/node

Conversation

@gibfahn

@gibfahn gibfahn commented Oct 24, 2017

Copy link
Copy Markdown
Member

If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as assert.deepStrictEqual() only shows you
the first three lines.

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • commit message follows commit guidelines
Affected core subsystem(s)

test

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@gibfahn gibfahn added the test Issues and PRs related to Node.js core tests and test infrastructure. label Oct 24, 2017
@gibfahn

gibfahn commented Oct 24, 2017

Copy link
Copy Markdown
Member Author

FWIW the motivation for this is running the tests in a docker container.

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

gireeshpunathil
gireeshpunathil approved these changes Oct 24, 2017
View reviewed changes
richardlau
richardlau reviewed Oct 24, 2017
View reviewed changes
Comment thread test/parallel/test-process-config.js Outdated

@richardlau richardlau Oct 24, 2017

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Are these necessary?

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

lpinca reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

@refack refack Oct 24, 2017

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe as the comment states, in case the assertion in L60 fails the output it will show will be truncated. This logging is so that we'll have the raw input.
This could be minimized by wrapping the assert in a try ... catch and log in the catch before rethrowing

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@gibfahn gibfahn Oct 24, 2017

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

See the comment. If the test passes nothing gets logged. If the test fails the assert just logs the first three lines, which is completely useless.

When this test fails it's usually because something is subtly different in your config, and you need to diff the two files to find out what it is.

This could be minimized by wrapping the assert in a try ... catch and log in the catch before rethrowing

Good idea.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@richardlau richardlau Oct 24, 2017

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the test fails the assert just logs the first three lines, which is completely useless.

Sounds like a problem with assert.deepStrictEqual, but that should be addressed elsewhere.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions

@gibfahn gibfahn Oct 24, 2017

Copy link
Copy Markdown
Member Author

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added a commit to wrap in try/catch.

I think the better fix is to use common.log(), but we haven't implemented that yet. I'll raise a PR for it later.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
jasnell
jasnell approved these changes Oct 24, 2017
View reviewed changes
refack
refack approved these changes Oct 24, 2017
View reviewed changes
Comment thread test/parallel/test-process-config.js Outdated

@refack refack Oct 24, 2017

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe as the comment states, in case the assertion in L60 fails the output it will show will be truncated. This logging is so that we'll have the raw input.
This could be minimized by wrapping the assert in a try ... catch and log in the catch before rethrowing

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
richardlau
richardlau approved these changes Oct 24, 2017
View reviewed changes
refack
refack approved these changes Oct 24, 2017
View reviewed changes

@refack refack left a comment

Copy link
Copy Markdown
Contributor

There was a problem hiding this comment.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🏆

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@mscdex mscdex added the process Issues and PRs related to the process subsystem. label Oct 24, 2017
lpinca
lpinca approved these changes Oct 25, 2017
View reviewed changes
@gibfahn

gibfahn commented Oct 25, 2017

Copy link
Copy Markdown
Member Author

CI: https://ci.nodejs.org/job/node-test-commit/13448/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@gibfahn
gibfahn force-pushed the process-config branch from b967d53 to 45f3a06 Compare October 27, 2017 11:20
@gibfahn
gibfahn force-pushed the process-config branch from 45f3a06 to 85daa2c Compare October 27, 2017 15:13
@gibfahn gibfahn closed this Oct 27, 2017
@gibfahn
gibfahn force-pushed the process-config branch from 85daa2c to 502563b Compare October 27, 2017 15:17
@gibfahn
gibfahn merged commit 502563b into nodejs:master Oct 27, 2017
@gibfahn
gibfahn deleted the process-config branch October 27, 2017 15:18
@refack

refack commented Oct 27, 2017

Copy link
Copy Markdown
Contributor

Follow up (just found this up):

node/tools/test.py

Line 941 in 22882d4

with open('config.gypi', 'r') as f:

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@jasnell jasnell mentioned this pull request Oct 30, 2017
Proposal: 2017-10-31, Version 9.0.0 (Current) #15135
Merged
@gibfahn gibfahn mentioned this pull request Oct 30, 2017
tools: allow running test.py without configuring #16621
Merged
2 tasks done
gibfahn added a commit that referenced this pull request Oct 30, 2017
@gibfahn
test: skip test-process-config if no config.gypi
9afc9bc
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
gibfahn added a commit that referenced this pull request Oct 30, 2017
@gibfahn
test: skip test-process-config if no config.gypi
d1ca3b9
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
gibfahn added a commit that referenced this pull request Oct 31, 2017
@gibfahn
test: skip test-process-config if no config.gypi
525700b
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
@gibfahn gibfahn mentioned this pull request Oct 31, 2017
v8.9.0 proposal #16630
Merged
Qard pushed a commit to ayojs/ayo that referenced this pull request Nov 2, 2017
@gibfahn @Qard
test: skip test-process-config if no config.gypi
68b1131
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: nodejs/node#16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Qard pushed a commit to ayojs/ayo that referenced this pull request Nov 2, 2017
@gibfahn @Qard
test: skip test-process-config if no config.gypi
add0859
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: nodejs/node#16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
@MylesBorins MylesBorins added the land-on-v6.x label Nov 16, 2017
MylesBorins pushed a commit that referenced this pull request Nov 16, 2017
@gibfahn @MylesBorins
test: skip test-process-config if no config.gypi
8cc5d5f
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
gibfahn added a commit to gibfahn/node that referenced this pull request Nov 20, 2017
@gibfahn
tools: allow running test.py without configuring
ad1967d
If config.gypi isn't defined, assume Node was build the default way,
i.e. with the inspector.

PR-URL: nodejs#16621
Refs: nodejs#16436 (comment)
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Daniel Bevenius <[email protected]>
@MylesBorins MylesBorins mentioned this pull request Nov 21, 2017
v6.12.1 proposal #17180
Merged
MylesBorins pushed a commit that referenced this pull request Nov 21, 2017
@gibfahn @MylesBorins
test: skip test-process-config if no config.gypi
075f1b7
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
MylesBorins pushed a commit that referenced this pull request Nov 28, 2017
@gibfahn @MylesBorins
test: skip test-process-config if no config.gypi
7d93da5
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: #16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
addaleax pushed a commit to ayojs/ayo that referenced this pull request Dec 7, 2017
@gibfahn @addaleax
test: skip test-process-config if no config.gypi
1137bf5
If you run the tests in a different machine to the one you built on,
this test will fail. Avoid this by skipping if the file doesn't exist.
We shouldn't need to check that the file exists in this test, as the
build won't pass without a config.gypi anyway.

Also adds console.logs, so you can see what the actual difference
between the objects was, as `assert.deepStrictEqual()` only shows you
the first three lines.

PR-URL: nodejs/node#16436
Reviewed-By: Gireesh Punathil <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Richard Lau <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
MylesBorins pushed a commit that referenced this pull request Dec 12, 2017
@gibfahn @MylesBorins
tools: allow running test.py without configuring
4954eef
If config.gypi isn't defined, assume Node was build the default way,
i.e. with the inspector.

PR-URL: #16621
Refs: #16436 (comment)
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Daniel Bevenius <[email protected]>
gibfahn added a commit that referenced this pull request Dec 19, 2017
@gibfahn
tools: allow running test.py without configuring
92e0e2e
If config.gypi isn't defined, assume Node was build the default way,
i.e. with the inspector.

PR-URL: #16621
Refs: #16436 (comment)
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Daniel Bevenius <[email protected]>
gibfahn added a commit that referenced this pull request Dec 20, 2017
@gibfahn
tools: allow running test.py without configuring
7658eec
If config.gypi isn't defined, assume Node was build the default way,
i.e. with the inspector.

PR-URL: #16621
Refs: #16436 (comment)
Reviewed-By: Refael Ackermann <[email protected]>
Reviewed-By: Anna Henningsen <[email protected]>
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Daniel Bevenius <[email protected]>
This was referenced May 13, 2024
[Snyk] Security upgrade eslint from 8.22.0 to 8.26.0 leonardoadame/node#818
Open
[Snyk] Fix for 2 vulnerabilities leonardoadame/node#839
Open
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@jasnell jasnell jasnell approved these changes
@lpinca lpinca lpinca approved these changes
@richardlau richardlau richardlau approved these changes
@gireeshpunathil gireeshpunathil gireeshpunathil approved these changes
+1 more reviewer
@refack refack refack approved these changes
Reviewers whose approvals may not affect merge requirements

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

process Issues and PRs related to the process subsystem. test Issues and PRs related to Node.js core tests and test infrastructure.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

8 participants

@gibfahn @refack @jasnell @lpinca @richardlau @gireeshpunathil @mscdex @MylesBorins
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.