Skip to content
This repository was archived by the owner on Jan 4, 2026. It is now read-only.
This repository was archived by the owner on Jan 4, 2026. It is now read-only.

bug(components with test harness example): Missing dependencies in StackBlitz examples #997

Closed

Description

@amysorto

Reproduction

This applies for the example that use test harness for all material components (except for ripples).

Steps to reproduce:

  1. Open the StackBlitz link for examples that have tests using a test harness in the 'Examples' page.

Expected Behavior

A working StackBlitz link for these examples. The examples in the documentation site for v11 work as expected (working example for tree component).

Actual Behavior

The StackBlitz link for v12 documentation for test harnesses show an error (failing example for tree component).

The error is the same for all:

Could not find a declaration file for module 'jasmine-core/lib/jasmine-core/jasmine.js'. '/turbo_modules/jasmine-core@3.7.1/lib/jasmine-core/jasmine.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/jasmine-core` if it exists or add a new declaration (.d.ts) file containing `declare module 'jasmine-core/lib/jasmine-core/jasmine.js';`

Environment

  • Angular: ^12.0.0
  • CDK/Material: ^12.0.0
  • Browser(s): Chrome 90
  • Operating System (e.g. Windows, macOS, Ubuntu): macOS

Activity

  1. Splaktar commented on May 26, 2021

    @Splaktar
    Contributor

    It looks like we need to add @types/jasmine-core to the following

    '@types/jasmine': '^3.6.6',
    'jasmine-core': '^3.6.0',


    I think that we need to add jasmine-core to this package.json as well.

  2. self-assigned this
    on May 26, 2021
  3. added a commit that references this issue on May 26, 2021
    9e29abc
  4. added a commit that references this issue on Jun 7, 2021
    b901073
  5. self-assigned this
    on Jun 7, 2021
  6. Splaktar commented on Jun 7, 2021

    @Splaktar
    Contributor

    It wasn't that easy at all. But I have a fix in PR #1009.

  7. added a commit that references this issue on Jul 19, 2021
    769a36c
  8. added a commit that references this issue on Jul 29, 2021
    e190dc4
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions