MCPcopy Index your code
hub / github.com/bvaughn/react-virtualized / verifySections

Function verifySections

source/Collection/SectionManager.jest.js:15–29  ·  view source on GitHub ↗
(
  sectionManager,
  sizeAndPosition,
  expectedSizeAndPositionInfos,
)

Source from the content-addressed store, hash-verified

13}
14
15function verifySections(
16 sectionManager,
17 sizeAndPosition,
18 expectedSizeAndPositionInfos,
19) {
20 const sections = sectionManager.getSections(sizeAndPosition);
21 expect(sections.length).toEqual(expectedSizeAndPositionInfos.length);
22 expectedSizeAndPositionInfos.forEach(sizeAndPosition => {
23 const match = sections.find(
24 section =>
25 section.x === sizeAndPosition.x && section.y === sizeAndPosition.y,
26 );
27 expect(!!match).toEqual(true);
28 });
29}
30
31describe('SectionManager', () => {
32 it('creates the appropriate number of Sections', () => {

Callers 1

Calls 1

getSectionsMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…