Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-1552

Update normalizedFunctionString to handle named functions

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: js-bson

      The normalizedFunctionString helper needs to be updated to standardize the string representation of named functions during testing. For example, passing in either of the following functions:

      function () {}

      or

      function func () {}

      should result in the same string representation:

      'function () {}'

      This will fix a bug in which there are discrepancies between the results of calling toString in the browser vs. in node, which becomes relevant when testing js-bson in the browser.
       

            Assignee:
            rebecca.weinberger Rebecca Weinberger
            Reporter:
            rebecca.weinberger Rebecca Weinberger
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: