Repository navigation
[core] Add essential unit tests for TMap - #23703
ravindra-RKB wants to merge 4 commits into
Conversation
Is this PR meant to be comprehensive? |
The “collision behavior” test could be enhanced to deliberately create a collision; it currently only checks Collisions() for ordinary keys. Also the ownership tests could cover both SetOwner() and SetOwnerValue() independently, or removal behavior when ownership is enabled. |
|
Thanks for the feedback @pcanal!
|
Test Results 24 files 24 suites 3d 23h 0m 56s ⏱️ Results for commit 0e237cf. ♻️ This comment has been updated with latest results. |
|
Side note (if you did not already read it), check https://github.com/root-project/root/blob/master/CONTRIBUTING.md |
|
Thanks for pointing that out @pcanal. I've re-read CONTRIBUTING.md, particularly the guidelines on AI disclosure and testing standards. Regarding the previous test failure, my previous attempt tried forcing a small capacity ( I have updated the test with a helper class that returns a fixed hash value and overrides |
|
Hi @pcanal, just following up on this. The branch is synced with latest master, and the collision and ownership tests are in place and passing cleanly across platforms. Whenever you have some time, could you please take a look? Thanks! |
|
Hi @pcanal - just a gentle ping on this. The branch is updated and all TMap unit tests are passing cleanly in CI. Could this be merged when you have a moment? Thank you! |
|
This PR needs to be rebased. I tried to help out with the rebase but it appears that this branch is not set to allow PR maintainer to push to it. |
651cc16 to
0e237cf
Compare
|
Hi @pcanal - thank you so much for helping with the rebase! All 29 CI checks are green now. Could this be merged when you have a moment? |
This Pull request:
Introduces essential unit tests for the
TMapassociative container incore/cont.Changes or fixes:
core/cont/test/TMapTest.cxxcovering:GetValue,operator(),FindObject)Remove(returning key) andRemoveEntry(returningTPair*)SetOwnervsSetOwnerValue), removal cleanup, andDeleteEntryRehashClear(),DeleteKeys(),DeleteValues(),DeleteAll(), and ownerClear()TIterTMapTestincore/cont/test/CMakeLists.txtChecklist: