Skip to content

Conversation

@kswenson
Copy link
Member

@kswenson kswenson commented Jan 14, 2026

[CODAP-1072] Case table should elide (with ...) text that doesn't fit

Also added a Copilot-written test suite for the renderAttributeValue() function.

@cypress
Copy link

cypress bot commented Jan 14, 2026

codap-v3    Run #9527

Run Properties:  status check passed Passed #9527  •  git commit 0cd5f531d3: chore: fix tests
Project codap-v3
Branch Review CODAP-1072-case-table-elision
Run status status check passed Passed #9527
Run duration 08m 04s
Commit git commit 0cd5f531d3: chore: fix tests
Committer Kirk Swenson
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 1
Tests that did not run due to a developer annotating a test with .skip  Pending 48
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 301
View all changes introduced in this branch ↗︎

@codecov
Copy link

codecov bot commented Jan 14, 2026

Codecov Report

❌ Patch coverage is 66.66667% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.55%. Comparing base (6d2e13f) to head (0cd5f53).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
v3/src/components/case-table/use-rows.ts 0.00% 3 Missing ⚠️
v3/src/components/case-table/case-table-types.ts 83.33% 1 Missing ⚠️
v3/src/components/case-table/row-divider.tsx 50.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2288      +/-   ##
==========================================
+ Coverage   86.53%   86.55%   +0.02%     
==========================================
  Files         723      723              
  Lines       38711    38719       +8     
  Branches     9194     9584     +390     
==========================================
+ Hits        33499    33514      +15     
+ Misses       5203     5196       -7     
  Partials        9        9              
Flag Coverage Δ
cypress 71.92% <35.71%> (-0.01%) ⬇️
jest 55.59% <66.66%> (+0.16%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@kswenson kswenson requested a review from bfinzer January 14, 2026 02:00
@kswenson kswenson marked this pull request as ready for review January 14, 2026 02:00
@kswenson kswenson requested review from Copilot and removed request for Copilot January 14, 2026 02:16
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

@kswenson kswenson requested a review from Copilot January 14, 2026 05:24
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

export const kDefaultRowHeight = 18
// used for row resizing
export const kRowHeightPadding = 4
export const kSnapToLineHeight = 14
Copy link

Copilot AI Jan 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The value of kDefaultRowHeight has changed from 18 to 18 (14 + 4). While mathematically equivalent, this change makes the constant dependent on other constants. Consider adding a comment explaining why kDefaultRowHeight equals kSnapToLineHeight + kRowHeightPadding to clarify the relationship between these values.

Suggested change
export const kSnapToLineHeight = 14
export const kSnapToLineHeight = 14
// Default row height is one snap line plus vertical padding so changes to either
// kSnapToLineHeight or kRowHeightPadding intentionally affect the default height.

Copilot uses AI. Check for mistakes.
}))

jest.mock("../../utilities/date-iso-utils", () => ({
isStdISODateString: jest.fn((str: string) => /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z$/.test(str))
Copy link

Copilot AI Jan 14, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The regex pattern is missing an escape for the literal dot before milliseconds. The pattern /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z$/ will match any character where the dot is. It should be /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/ to match the literal dot in ISO date strings.

Suggested change
isStdISODateString: jest.fn((str: string) => /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z$/.test(str))
isStdISODateString: jest.fn((str: string) => /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}\.\d{3}Z$/.test(str))

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants