Skip to content

Commit d02ae69

Browse files
committed
feat(ui): Extend build system issue category patterns
Signed-off-by: Sebastian Schuberth <[email protected]>
1 parent b4aa934 commit d02ae69

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

ui/src/helpers/get-issue-category.ts

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,10 @@ const issueCategoryMap: Record<IssueCategory, RegExp[]> = {
3737
/StreamResetException: stream was reset*/,
3838
],
3939
'Missing Data': [/Could not resolve provenance for .*/],
40-
'Build System': [/.* failed to resolve dependencies for .*/],
40+
'Build System': [
41+
/.* failed to resolve dependencies for .*/,
42+
/^Multiple projects with the same id .*/,
43+
],
4144
Other: [/.*/],
4245
};
4346

@@ -103,9 +106,14 @@ if (import.meta.vitest) {
103106
});
104107

105108
it('correctly categorizes build system issues', () => {
106-
const message =
107-
"GradleInspector failed to resolve dependencies for path 'android/build.gradle':";
108-
expect(getIssueCategory(message)).toBe('Build System');
109+
const messages = [
110+
"GradleInspector failed to resolve dependencies for path 'android/build.gradle':",
111+
"Multiple projects with the same id 'NPM::project:1.0.0' found.",
112+
];
113+
114+
messages.forEach((message) => {
115+
expect(getIssueCategory(message)).toBe('Build System');
116+
});
109117
});
110118

111119
it('correctly categorizes other issues', () => {

0 commit comments

Comments
 (0)