5122f9e3fb6070a367d747b3d031f68ce9f93aa9dcb380fc9ef8e257971080a7448af31c2ff2059dd6430e82d894647550f53fa1c445f4a9c2773b9ec40fe6 648 B

123456789101112131415161718192021222324252627
  1. describe('Core.toPhysicalColumn', () => {
  2. var id = 'testContainer';
  3. beforeEach(function() {
  4. this.$container = $(`<div id="${id}"></div>`).appendTo('body');
  5. });
  6. afterEach(function() {
  7. if (this.$container) {
  8. destroy();
  9. this.$container.remove();
  10. }
  11. });
  12. it('should return valid physical row index', () => {
  13. var hot = handsontable({
  14. data: Handsontable.helper.createSpreadsheetData(10, 10),
  15. modifyCol(column) {
  16. return column + 3;
  17. }
  18. });
  19. expect(hot.toPhysicalColumn(0)).toBe(3);
  20. expect(hot.toPhysicalColumn(1)).toBe(4);
  21. expect(hot.toPhysicalColumn(2)).toBe(5);
  22. });
  23. });