Revert "Clicking a link in the HTML reporter does exact filtering"

This change broke spec filtering in Karma by changing the format of the
`spec` query parameter. Although karma-jasmine-html-reporter uses
jasmine-core's HtmlSpecFilter, karm-jasmine provides its own spec filter
that interprets the query parameters itself.

This feature may be reintroduced in 6.0 as a breaking change.

This reverts commit 8309416cb2.
This commit is contained in:
Steve Gravrock
2025-10-05 09:59:36 -07:00
parent 489b83c61b
commit dbc1f9244e
10 changed files with 52 additions and 279 deletions

View File

@@ -81,14 +81,14 @@
/**
* Filter which specs will be run by matching the start of the full name against the `spec` query param.
*/
const specFilter = new jasmine.HtmlExactSpecFilter({
const specFilter = new jasmine.HtmlSpecFilter({
filterString: function() {
return queryString.getParam('spec');
}
});
config.specFilter = function(spec) {
return specFilter.matches(spec);
return specFilter.matches(spec.getFullName());
};
env.configure(config);