Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-23704

shard_keycount.js does not invoke anonymous function

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: 3.2.0-rc1
    • Fix Version/s: 3.2.6, 3.3.5
    • Component/s: Sharding
    • Labels:
    • Backwards Compatibility:
      Fully Compatible
    • Operating System:
      ALL
    • Backport Completed:

      Description

      This causes the jstest to accidentally not be run, and so always pass.

      https://github.com/mongodb/mongo/blob/r3.3.4/jstests/sharding/shard_keycount.js#L46

      Just needs

      diff --git a/jstests/sharding/shard_keycount.js b/jstests/sharding/shard_keycount.js
      index 9a63a2c..893e201 100644
      --- a/jstests/sharding/shard_keycount.js
      +++ b/jstests/sharding/shard_keycount.js
      @@ -43,4 +43,4 @@
       
           s.stop();
       
      -});
      +})();
      

      Command where this was noticed (this seems to be the only occurrence, but I didn't check thoroughly)

      for i in `grep -l '^(function *()' jstests/*/*`; do echo; echo "$i"; tail -1 "$i"; done
      

      cc Kamran K.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: