From d038f46152341b0afb15b191f34a4b60a074d7a8 Mon Sep 17 00:00:00 2001 From: Yihui Liao <44729383+yihuiliao@users.noreply.github.com> Date: Fri, 31 Jul 2026 13:30:59 -0700 Subject: [PATCH] chore: update testing sheet script (#10382) * add labels * add ai label * add ai to testing sheet * fix formatting --- .github/labeler.yml | 48 ++++++++++++++++++++++++++++++++ scripts/createExcelSheet.mjs | 18 +++++++----- scripts/getCommitsForTesting.mjs | 27 ++++++++++++++++-- scripts/sendWeeklyExcelSheet.mjs | 13 +++++---- 4 files changed, 91 insertions(+), 15 deletions(-) diff --git a/.github/labeler.yml b/.github/labeler.yml index c3350301447..c628632fae5 100644 --- a/.github/labeler.yml +++ b/.github/labeler.yml @@ -22,6 +22,10 @@ v3: - all-globs-to-any-file: ['**/@react-spectrum/**', '!**/*.stories.*', '!**/*.test.*'] - all-globs-to-all-files: ['!**/@react-spectrum/s2/**', '!**/@react-spectrum/ai/**'] +AI: + - changed-files: + - all-globs-to-any-file: ['**/ai/**', '!**/*.stories.*', '!**/*.test.*'] + Accordion: - changed-files: - any-glob-to-any-file: '**/Accordion.tsx' @@ -42,6 +46,10 @@ ActionMenu: - changed-files: - any-glob-to-any-file: '**/ActionMenu.tsx' +AttachmentList: + - changed-files: + - any-glob-to-any-file: '**/AttachmentList.tsx' + Autocomplete: - changed-files: - any-glob-to-any-file: '**/Autocomplete.tsx' @@ -82,6 +90,10 @@ CardView: - changed-files: - any-glob-to-any-file: '**/CardView.tsx' +Chat: + - changed-files: + - any-glob-to-any-file: '**/Chat.tsx' + Checkbox: - changed-files: - any-glob-to-any-file: '**/Checkbox.tsx' @@ -174,6 +186,10 @@ Group: - changed-files: - any-glob-to-any-file: '**/Group.tsx' +HorizontalCard: + - changed-files: + - any-glob-to-any-file: '**/HorizontalCard.tsx' + I18nProvider: - changed-files: - any-glob-to-any-file: '**/I18nProvider.tsx' @@ -210,6 +226,18 @@ Menu: - changed-files: - any-glob-to-any-file: '**/Menu.tsx' +MessageFeedback: + - changed-files: + - any-glob-to-any-file: '**/MessageFeedback.tsx' + +MessageSource: + - changed-files: + - any-glob-to-any-file: '**/MessageSource.tsx' + +MessageSuggestionList: + - changed-files: + - any-glob-to-any-file: '**/MessageSuggestionList.tsx' + Meter: - changed-files: - any-glob-to-any-file: '**/Meter.tsx' @@ -238,6 +266,14 @@ ProgressCircle: - changed-files: - any-glob-to-any-file: '**/ProgressCircle.tsx' +PromptField: + - changed-files: + - any-glob-to-any-file: '**/PromptField.tsx' + +Prose: + - changed-files: + - any-glob-to-any-file: '**/Prose.tsx' + RadioGroup: - changed-files: - any-glob-to-any-file: '**/RadioGroup.tsx' @@ -250,6 +286,10 @@ RangeSlider: - changed-files: - any-glob-to-any-file: '**/RangeSlider.tsx' +ResponseStatus: + - changed-files: + - any-glob-to-any-file: '**/ResponseStatus.tsx' + SearchField: - changed-files: - any-glob-to-any-file: '**/SearchField.tsx' @@ -322,6 +362,10 @@ ToggleButtonGroup: - changed-files: - any-glob-to-any-file: '**/ToggleButtonGroup.tsx' +TokenField: + - changed-files: + - any-glob-to-any-file: '**/TokenField.tsx' + Toolbar: - changed-files: - any-glob-to-any-file: '**/Toolbar.tsx' @@ -337,3 +381,7 @@ Tree: TreeView: - changed-files: - any-glob-to-any-file: '**/TreeView.tsx' + +UserMessage: + - changed-files: + - any-glob-to-any-file: '**/UserMessage.tsx' diff --git a/scripts/createExcelSheet.mjs b/scripts/createExcelSheet.mjs index 4b77252e281..bca4a927fa4 100644 --- a/scripts/createExcelSheet.mjs +++ b/scripts/createExcelSheet.mjs @@ -57,7 +57,7 @@ function buildBugsNotesSheet(workbook) { } } -function buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}) { +function buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}) { let sheet = workbook.addWorksheet('Release Notes'); sheet.columns = [{width: 25}, {width: 70}, {width: 50}, {width: 50}]; @@ -67,6 +67,7 @@ function buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPR let groups = [ ['RAC', racPRs], ['S2', s2PRs], + ['AI', aiPRs], ['V3', v3PRs], ['Other', otherPRs], ['Off PRs', offPRs] @@ -99,7 +100,7 @@ function buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPR } } -function buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}) { +function buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}) { let sheet = workbook.addWorksheet('Pass-Fail'); sheet.columns = [ @@ -149,7 +150,8 @@ function buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}) {row: 2, label: 'Next'}, {row: 3, label: 'S2 Parcel'}, {row: 4, label: 'S2 Webpack'}, - {row: 5, label: 'RAC Tailwind'} + {row: 5, label: 'S2 Next'}, + {row: 6, label: 'S2 Vite'} ]; for (let {row, label} of categoryE) { sheet.getCell(`E${row}`).value = label; @@ -176,8 +178,10 @@ function buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}) ['RAC', racPRs], ['S2', s2PRs], ['V3', v3PRs], + ['AI', aiPRs], ['Other', otherPRs], - ['Off PRs', offPRs] + ['Off PRs', offPRs], + ['Test Apps', [['Next'], ['S2 Parcel'], ['S2 Webpack'], ['S2 Next'], ['S2 Vite']]] ]; let nextRow = 11; let first = true; @@ -255,13 +259,13 @@ function buildScreenshotsSheet(workbook) { header.height = 50; } -export async function createTestingSheet({v3PRs, s2PRs, racPRs, otherPRs, offPRs}) { +export async function createTestingSheet({v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}) { let workbook = new ExcelJS.Workbook(); - buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}); + buildPassFailSheet(workbook, {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}); buildScreenshotsSheet(workbook); buildBugsNotesSheet(workbook); - buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, otherPRs, offPRs}); + buildReleaseNotesSheet(workbook, {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}); return workbook.xlsx.writeBuffer(); } diff --git a/scripts/getCommitsForTesting.mjs b/scripts/getCommitsForTesting.mjs index 66d4e5be4fd..44261c82c7f 100644 --- a/scripts/getCommitsForTesting.mjs +++ b/scripts/getCommitsForTesting.mjs @@ -63,6 +63,7 @@ export async function generateData(startDate, endDate) { let s2PRs = []; let racPRs = []; let v3PRs = []; + let aiPRs = []; let otherPRs = []; // Off PRs are currently open PRs with the 'test off PR' label @@ -126,7 +127,7 @@ export async function generateData(startDate, endDate) { row.push(info.data.html_url); row.push(removePRNumber(title)); - if (!labels.has('S2') && !labels.has('RAC') && !labels.has('v3')) { + if (!labels.has('S2') && !labels.has('RAC') && !labels.has('v3') && !labels.has('AI')) { otherPRs.push(row); } else { if (labels.has('S2')) { @@ -138,6 +139,9 @@ export async function generateData(startDate, endDate) { if (labels.has('v3')) { v3PRs.push(row); } + if (labels.has('AI')) { + aiPRs.push(row); + } } } @@ -145,12 +149,14 @@ export async function generateData(startDate, endDate) { v3PRs, s2PRs, racPRs, + aiPRs, otherPRs, offPRs, counts: { v3: v3PRs.length, s2: s2PRs.length, rac: racPRs.length, + ai: aiPRs.length, offPRs: offPRs.length, other: otherPRs.length } @@ -158,7 +164,10 @@ export async function generateData(startDate, endDate) { } export async function generateCSV(startDate, endDate) { - let {v3PRs, s2PRs, racPRs, otherPRs, offPRs, counts} = await generateData(startDate, endDate); + let {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs, counts} = await generateData( + startDate, + endDate + ); function formatRows(rows) { return rows @@ -168,7 +177,7 @@ export async function generateCSV(startDate, endDate) { .join('\n'); } - let csv = `V3 \n${formatRows(v3PRs)}\n\nRainbow \n${formatRows(s2PRs)}\n\nRAC \n${formatRows(racPRs)}\n\nOff PR \n${formatRows(offPRs)}\n\nOther \n${formatRows(otherPRs)}\n`; + let csv = `V3 \n${formatRows(v3PRs)}\n\nRainbow \n${formatRows(s2PRs)}\n\nRAC \n${formatRows(racPRs)}\n\nAI \n${formatRows(aiPRs)}\n\nOff PR \n${formatRows(offPRs)}\n\nOther \n${formatRows(otherPRs)}\n`; return {csv, counts}; } @@ -301,6 +310,7 @@ let validLabels = new Set([ 'ActionButton', 'ActionButtonGroup', 'ActionMenu', + 'AttachmentList', 'Autocomplete', 'Avatar', 'AvatarGroup', @@ -310,6 +320,7 @@ let validLabels = new Set([ 'ButtonGroup', 'Calendar', 'Card', + 'Chat', 'CardView', 'Checkbox', 'CheckboxGroup', @@ -336,6 +347,7 @@ let validLabels = new Set([ 'Form', 'GridList', 'Group', + 'HorizontalCard', 'I18nProvider', 'IllustratedMessage', 'Image', @@ -345,6 +357,9 @@ let validLabels = new Set([ 'LinkButton', 'ListBox', 'Menu', + 'MessageFeedback', + 'MessageSource', + 'MessageSuggestionList', 'Meter', 'Modal', 'NumberField', @@ -353,15 +368,19 @@ let validLabels = new Set([ 'PortalProvider', 'ProgressBar', 'ProgressCircle', + 'PromptField', + 'Prose', 'Provider', 'RadioGroup', 'RangeCalendar', 'RangeSlider', + 'ResponseStatus', 'SearchField', 'SegmentedControl', 'Select', 'SelectBoxGroup', 'Separator', + 'SideNav', 'Skeleton', 'Slider', 'SSRProvider', @@ -377,10 +396,12 @@ let validLabels = new Set([ 'Toast', 'ToggleButton', 'ToggleButtonGroup', + 'TokenField', 'Toolbar', 'Tooltip', 'Tree', 'TreeView', + 'UserMessage', 'Virtualizer', 'VisuallyHidden', 'documentation', diff --git a/scripts/sendWeeklyExcelSheet.mjs b/scripts/sendWeeklyExcelSheet.mjs index ee8b1098769..7d34869057a 100644 --- a/scripts/sendWeeklyExcelSheet.mjs +++ b/scripts/sendWeeklyExcelSheet.mjs @@ -112,18 +112,21 @@ async function main() { })(); console.log(`Generating testing sheet for ${startDate} – ${endDate}...`); - let {v3PRs, s2PRs, racPRs, otherPRs, offPRs, counts} = await generateData(startDate, endDate); + let {v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs, counts} = await generateData( + startDate, + endDate + ); console.log( - `Found: V3=${counts.v3}, S2=${counts.s2}, RAC=${counts.rac}, Other=${counts.other}, Off PRs=${counts.offPRs}` + `Found: V3=${counts.v3}, S2=${counts.s2}, RAC=${counts.rac}, AI=${counts.ai}, Other=${counts.other}, Off PRs=${counts.offPRs}` ); - let buffer = await createTestingSheet({v3PRs, s2PRs, racPRs, otherPRs, offPRs}); + let buffer = await createTestingSheet({v3PRs, s2PRs, racPRs, aiPRs, otherPRs, offPRs}); let startLabel = formatDateLabel(startDate); let endLabel = formatDateLabel(endDate); - let total = counts.v3 + counts.s2 + counts.rac + counts.other; + let total = counts.v3 + counts.s2 + counts.rac + counts.ai + counts.other; let filename = `${endLabel}.xlsx`; - let message = `*Testing sheet for ${startLabel} – ${endLabel}*\nV3: ${counts.v3} | S2: ${counts.s2} | RAC: ${counts.rac} | Other: ${counts.other} | Off PR: ${counts.offPRs} | Total: ${total}`; + let message = `*Testing sheet for ${startLabel} – ${endLabel}*\nV3: ${counts.v3} | S2: ${counts.s2} | RAC: ${counts.rac} | AI: ${counts.ai} | Other: ${counts.other} | Off PR: ${counts.offPRs} | Total: ${total}`; if (isLocal) { let outPath = path.resolve(process.cwd(), filename);