Uploaded image for project: 'Fluid Infusion'
  1. Fluid Infusion
  2. FLUID-6429

Syllabification enactor tests apply faulty escaping in selector causing no test to execute

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None

      Description

      The Syllabification Enactor tests at https://github.com/fluid-project/infusion/blob/master/tests/framework- tests/preferences/js/SyllabificationEnactorTests.js#L293 apply faulty escaping in the following block:

                      combined: {
                          ".flc-syllabification-injectWhenDisabled": "{that}.options.testOpts.injected.disabled.\.flc-syllabification-injectWhenDisabled",
                          ".flc-syllabification-injectWhenEnabled": "{that}.options.testOpts.injected.disabled.\.flc-syllabification-injectWhenEnabled"
                      }
      

      In a JavaScript string, the escape sequence "\." is simply equivalent to "." and the proper escaping would have been "
      .". The result is that these values are undefined and no tests are executed. However, because of FLUID-6430 even if the correct escaping had been applied, the reference would still not resolve. The best disposition is to rewrite the test so that the index is a plain string, perhaps a selector name, rather than a full CSS class selector.

        Attachments

          Activity

            People

            • Assignee:
              jobara Justin Obara
              Reporter:
              antranig Antranig Basman
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: