react-component / react-component/table
Fixed columns make tests fail: TypeError: this.rowRef.getBoundingClientRect is not a function
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.4k
- Forks
- 618
- Avg merge
- 10h 19m
- Merged PRs (30d)
- 2
Description
I am using the rc-table to display some data.
When I add some fixed columns, the jest test starts failing with:
TypeError: this.rowRef.getBoundingClientRect is not a function.
When I remove the fixed property, the test runs without issue... This looks like a bug to me.... Could you have a look and/or tell me a work around?
Thanks in advance,
Gioia
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the Jest failure with rc-table fixed columns enabled and compare it with the non-fixed-column case. Trace the fixed-column rendering path to the use of rowRef and determine why the test environment does not provide getBoundingClientRect. Done means the failing test passes while fixed columns continue to work.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend, testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100