Skip to content

TestBed aotSummaries #2162

Open
Open

Description

@brian428

[X] feature request

Apparently, Angular added a feature called aotSummaries to TestBed.initTestEnvironment() at some point (https://angular.io/api/core/testing/TestBed#initTestEnvironment). But the docs are pretty sparse. Could the seed be updated to support these? Apparently, it makes unit tests run much faster because the HTML templates aren't constantly recompiled for every spec method.

Activity

  1. brian428 commented on Dec 12, 2017

    @brian428
    ContributorAuthor

    In case you think you might look into this, here's a repo that seems to include the ability to use aotSummaries for tests: https://github.com/Quramy/test-with-aot-summary

    I took a look and I'm not really sure what he's doing with his shell script. But I thought maybe this could provide some useful info if you think this is worth adopting. I know from experience that running tests where the templates are not recompiled for every spec method will reduce the time it takes to run tests by 50-75%. For me, the difference for 600+ tests was over 5 minutes faster per run.

  2. mgechev commented on Dec 13, 2017

    @mgechev
    Owner

    Hey @brian428 this issue is not priority for my use case of Angular Seed. If you have time would love to review and merge PR which introduces the feature.

  3. brian428 commented on Dec 13, 2017

    @brian428
    ContributorAuthor

    I may try to take a stab at it, but much of the low-level AoT stuff is baffling to me. It doesn't help that the docs don't really say anything about how this works. But if I can figure it out, I'll certainly send a PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions