Skip to content

bug(COMPONENT): MatExpansionPanelHarness #29454

Closed

Description

Is this a regression?

No response

The previous version in which this bug was not present was

No response

Description

The filters on MatExpansionPanelHarness seem to be not working correctly.

Reproduction

Run a test with the following content:

const expansionPanels = await loader.getHarness(MatExpansionPanelHarness.with({ disabled: true }));

Expected Behavior

I get a list of MatExpansionPanelHarness that are disabled

Actual Behavior

I get the error:

SyntaxError: '' is not a valid selector
at emit (/node_modules/nwsapi/src/nwsapi.js:575:17)
at Object._querySelectorAll [as select] (/node_modules/nwsapi/src/nwsapi.js:1491:9)
at HTMLDivElementImpl.querySelectorAll (node_modules/jsdom/lib/jsdom/living/nodes/ParentNode-impl.js:78:26)
at HTMLDivElement.querySelectorAll (node_modules/jsdom/lib/jsdom/living/generated/Element.js:1119:58)
at Object.queryFn (node_modules/@angular/cdk/fesm2022/testing/testbed.mjs:622:39)
at TestbedHarnessEnvironment.getAllRawElements (node_modules/@angular/cdk/fesm2022/testing/testbed.mjs:770:41)

Environment

  • Angular: 18.1.1
  • CDK/Material: 18.1.1
  • Browser(s): -
  • Operating System (e.g. Windows, macOS, Ubuntu): Ubuntu
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    needs triageThis issue needs to be triaged by the teamThis issue needs to be triaged by the team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions