File tree Expand file tree Collapse file tree 1 file changed +50
-0
lines changed Expand file tree Collapse file tree 1 file changed +50
-0
lines changed Original file line number Diff line number Diff line change @@ -648,4 +648,54 @@ describe("veTable virtual scroll", () => {
648648 const rowCount = getTableRenderedRowCountByRowHeight ( minRowHeight ) ;
649649 expect ( wrapper . findAll ( ".ve-table-body-tr" ) . length ) . toBe ( rowCount ) ;
650650 } ) ;
651+
652+ // it("virtual scroll placeholder", async () => {
653+ // const wrapper = mount(veTable, {
654+ // propsData: {
655+ // columns: [
656+ // {
657+ // field: "name",
658+ // key: "b",
659+ // title: "Name",
660+ // width: 200,
661+ // align: "left",
662+ // },
663+ // {
664+ // field: "hobby",
665+ // key: "c",
666+ // title: "Hobby",
667+ // width: 300,
668+ // align: "left",
669+ // },
670+ // {
671+ // field: "address",
672+ // key: "d",
673+ // title: "Address",
674+ // width: "",
675+ // align: "left",
676+ // },
677+ // ],
678+ // tableData: TABLE_DATA_SAME_ROW_HEIGHT,
679+ // virtualScrollOption: {
680+ // // 是否开启
681+ // enable: true,
682+ // },
683+ // maxHeight: MAX_HEIGHT,
684+ // rowKeyFieldName: "rowKey",
685+ // },
686+ // });
687+
688+ // wrapper.triggerResizeObserver({ width: MAX_HEIGHT });
689+
690+ // await later();
691+
692+ // const scrollToFn = mockScrollTo();
693+
694+ // wrapper.vm.scrollTo({ top: 1000 });
695+
696+ // await later(2000);
697+
698+ // // how to test?
699+ // expect(wrapper.vm.showVirtualScrollingPlaceholder).toEqual(true);
700+ // });
651701} ) ;
You can’t perform that action at this time.
0 commit comments