[SERVER-30922] resmoke should error if you give it a nonexistent jstest on the command line Created: 01/Sep/17  Updated: 30/Oct/23  Resolved: 06/Oct/17

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: 3.6.0-rc0

Type: Improvement Priority: Major - P3
Reporter: Eric Milkie Assignee: Yves Duhem
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Problem/Incident
Related
is related to SERVER-28302 resmoke.py parser should accept files... Closed
Backwards Compatibility: Fully Compatible
Sprint: TIG 2017-10-02, TIG 2017-10-23
Participants:
Linked BF Score: 0

 Description   

Currently, if you do something like this by mistake:

buildscripts/resmoke.py jstests/noPassthrough/blarf.js

..there is a lot of output but nothing that indicates an error or that the specified file wasn't actually found on disk.



 Comments   
Comment by Githook User [ 06/Oct/17 ]

Author:

{'email': 'yves.duhem@mongodb.com', 'name': 'Yves Duhem', 'username': 'syev'}

Message: SERVER-30922 Do not fail on non matching selector pattern
Branch: master
https://github.com/mongodb/mongo/commit/203c2103327b8ac24fcc7b1ebcaab2a359f4b7f8

Comment by Githook User [ 06/Oct/17 ]

Author:

{'email': 'yves.duhem@mongodb.com', 'name': 'Yves Duhem', 'username': 'syev'}

Message: SERVER-30922 Fail on invalid resmoke test file arguments
Branch: master
https://github.com/mongodb/mongo/commit/5d1c412f41a42dd69c5e76d7aafc9efa3b204678

Comment by Max Hirschhorn [ 01/Sep/17 ]

Prior to the changes from b6c1b6b as part of SERVER-28302 to support running non-JavaScript tests through resmoke.py, we would error out with the following message:

$ buildscripts/resmoke.py jstests/noPassthrough/blarf.js
[resmoke] 2017-09-01T13:48:42.098-0400 resmoke.py invocation: buildscripts/resmoke.py jstests/noPassthrough/blarf.js
Traceback (most recent call last):
  File "buildscripts/resmoke.py", line 198, in <module>
    main()
  File "buildscripts/resmoke.py", line 153, in main
    suites = resmokelib.parser.get_suites(values, args)
  File "/home/maxh/debugging/mongo/buildscripts/resmokelib/parser.py", line 330, in get_suites
    suite_config = _make_jstests_config(args)
  File "/home/maxh/debugging/mongo/buildscripts/resmokelib/parser.py", line 410, in _make_jstests_config
    % (pathname))
optparse.OptionValueError: Expected a list of JS files, but got 'jstests/noPassthrough/blarf.js'

The call to os.path.isfile() was removed in order to accomodate running specific dbtest test suites through resmoke.py. I think we could make it so that the "js_test" test kind (and others except for "db_test" and "mongos_test") error out if the list of tests to run aren't files that exist on disk.

Generated at Thu Feb 08 04:25:27 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.