Skip to content

Running unit tests in a new HTML Document creates failures in non-Chrome browsers #3475

Closed

Description

@marclaval

2 weeks ago, we started running unit tests in a new HTML Document, see: https://github.com/angular/angular/blob/master/modules/angular2/src/test_lib/test_injector.ts#L96
If it works fine in Chrome, it creates problems in other browsers.

The biggest one is for Safari where events are not dispatched in such a document. This causes the 26 events-based unit tests to fail there.
It also generates one failure in Firefox and IE11. In Firefox, the default behaviour of an event is not applied (e.g. checkbox not checked after a click). In IE11, text selection feature doesn"t work.

Moving back to the real DOM doesn't seem to degrade performances, but it means loosing the isolation that is brought by a new Document. But it seems needed to be able to integrate these browsers to CI.

Activity

  1. added a commit that references this issue on Aug 7, 2015
    a37de36
  2. added a commit that references this issue on Aug 15, 2015
    2612546
  3. angular-automatic-lock-bot commented on Sep 6, 2019

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  4. locked and limited conversation to collaborators on Sep 6, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions