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

The test written in IoC testing framework runs fine on its own but throws error in all-tests.html

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.5.1
    • Fix Version/s: None
    • Component/s: IoC Testing Framework
    • Labels:
      None
    • Environment:
      Firefox, Chrome. Didn't test with Safari and IE

      Description

      The test to re-produce this issue is,

      https://github.com/cindyli/universal/blob/GPII-1245-odd/gpii/node_modules/gpii-oauth2/gpii-oauth2-authz-server/webTests/components/privacySettings/html/PrivacySettingsWithPrefs-test.html

      When running this test on its own, all tests pass. However, when including it as a part of all-tests.html (https://github.com/cindyli/universal/blob/GPII-1245-odd/gpii/node_modules/gpii-oauth2/gpii-oauth2-authz-server/webTests/all-tests.html), a javascript error is thrown:

      Expected at least one assertion, but none were run - call expect(0) to accept zero assertions.
      Source:
      QUnit.asyncTest@http://localhost/gpii/node_modules/universal/node_modules/infusion/tests/lib/qunit/js/qunit.js:401:3

      After investigation, the issue is caused by the missing "name" field in the "tests" block. Rewriting this block (https://github.com/cindyli/universal/blob/GPII-1245-odd/gpii/node_modules/gpii-oauth2/gpii-oauth2-authz-server/webTests/components/privacySettings/js/PrivacySettingsWithPrefsTests.js#L46-L51) by adding a "name" field resolves the issue.

      The block that works:
      tests: [{
      name: "a test",
      sequence: [

      { .... }

      ]
      }]

        Attachments

          Activity

            People

            Assignee:
            antranig Antranig Basman
            Reporter:
            cli@ocad.ca Cindy Qi Li
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: