Skip to content

tools: allow test.py to use full paths of tests - #9694

Closed
reconbot wants to merge 1 commit into
nodejs:masterfrom
reconbot:testpy-paths
Closed

tools: allow test.py to use full paths of tests#9694
reconbot wants to merge 1 commit into
nodejs:masterfrom
reconbot:testpy-paths

Conversation

@reconbot

@reconbotreconbot commented Nov 19, 2016

Copy link
Copy Markdown
Contributor
Checklist
  • commit message follows commit guidelines
  • ran test suite, no new tests
Affected core subsystem(s)

Fixes: #9684
tools/test.py can now take paths like

$ python tools/test.py test/parallel/test-cluster-worker-init.js
$ python tools/test.py test/parallel/test-cluster-worker-init
$ python tools/test.py parallel/test-cluster-worker-init.js
Description of change

Slices off the test/ and the .js on input files. Wildcards like parallel/test-cluster-* will still work as will defaults.

@nodejs-github-botnodejs-github-bot added the tools Issues and PRs related to the tools directory. label Nov 19, 2016
@Fishrock123

Copy link
Copy Markdown
Contributor

@MylesBorinsMylesBorins left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM if CI is green

@gibfahngibfahn left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looking forward to no more No tests to run because you copied the .js as well. Also tab-complete for tests is great.

@reconbot

Copy link
Copy Markdown
ContributorAuthor

@thealphanerd freebsd failed but I can't figure out what failed, I see "no failures"

screen shot 2016-11-19 at 10 35 51 am

@MylesBorins

MylesBorins commented Nov 19, 2016

Copy link
Copy Markdown
Contributor

failure looks infra related /cc @nodejs/build

fixes #9684

@addaleaxaddaleax left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM

@jbergstroem

Copy link
Copy Markdown
Member

@thealphanerd what you meant to say was "the failure looks @jbergstroem-related". Should be fixed now.

@MylesBorins

Copy link
Copy Markdown
Contributor

@jbergstroem you are a hero! Thank you for all the hard infra work you do.

@jbergstroem

Copy link
Copy Markdown
Member

@thealphanerd thanks! if only the work wasn't so tied to fixing my other work :)

Comment threadtools/test.py Outdated

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Use startswith and endswith.

Allow test.py to run tests with a 'tests/' prefix or a '.js' postfix
Fixes: nodejs#9684
@reconbot

Copy link
Copy Markdown
ContributorAuthor

@thefourtheye updated to use startswith and endswith.

@thefourtheyethefourtheye left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Nice. LGTM. Thanks :)

@MylesBorins

Copy link
Copy Markdown
Contributor

landed in 951ba0d

MylesBorins pushed a commit that referenced this pull request Nov 26, 2016
Allow test.py to run tests with a 'tests/' prefix or a '.js' postfix
PR-URL: #9694Fixes: #9684
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
MylesBorins pushed a commit that referenced this pull request Nov 26, 2016
Allow test.py to run tests with a 'tests/' prefix or a '.js' postfix
PR-URL: #9694Fixes: #9684
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
MylesBorins pushed a commit that referenced this pull request Nov 26, 2016
Allow test.py to run tests with a 'tests/' prefix or a '.js' postfix
PR-URL: #9694Fixes: #9684
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
MylesBorins pushed a commit that referenced this pull request Nov 26, 2016
Allow test.py to run tests with a 'tests/' prefix or a '.js' postfix
PR-URL: #9694Fixes: #9684
Reviewed-By: Prince John Wesley <princejohnwesley@gmail.com>
Reviewed-By: Myles Borins <myles.borins@gmail.com>
Reviewed-By: Anna Henningsen <anna@addaleax.net>
Reviewed-By: Sakthipriyan Vairamani <thechargingvolcano@gmail.com>
Reviewed-By: Gibson Fahnestock <gibfahn@gmail.com>
@reconbot
reconbot deleted the testpy-paths branch November 27, 2016 16:38
@MylesBorinsMylesBorins mentioned this pull request Dec 1, 2016
@Fishrock123Fishrock123 mentioned this pull request Dec 5, 2016
2 tasks
@MylesBorinsMylesBorins mentioned this pull request Dec 6, 2016
@richardlaurichardlau mentioned this pull request Aug 16, 2019
2 tasks
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

toolsIssues and PRs related to the tools directory.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

9 participants

@reconbot@Fishrock123@MylesBorins@jbergstroem@thefourtheye@addaleax@princejwesley@gibfahn@nodejs-github-bot