Skip to content

Commit

Permalink
Merge branch 'sstoyanov/bug-fix-2951' of https://github.com/IgniteUI/…
Browse files Browse the repository at this point in the history
…igniteui-angular into sstoyanov/bug-fix-2951
  • Loading branch information
sstoyanovIG committed Nov 8, 2018
2 parents 145c5d5 + bfc3ce1 commit 8b6724a
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 27 deletions.
14 changes: 7 additions & 7 deletions ROADMAP.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,16 @@
## Milestone 5 (by November 30th, 2018)

1. Hierarchical Grid POC (Proof of concept) [issue](https://github.com/IgniteUI/igniteui-angular/issues/827)
2. Tree Grid [issue](https://github.com/IgniteUI/igniteui-angular/issues/2530)
2. **[Done]**Tree Grid [issue](https://github.com/IgniteUI/igniteui-angular/issues/2530)
3. Implement number-of-records-based rendering for igxGrid [issue](https://github.com/IgniteUI/igniteui-angular/issues/2384)
4. Advanced Filtering Dialog
5. Quick Per-column Search in the igxGrid [issue](https://github.com/IgniteUI/igniteui-angular/issues/542)
6. Expandable Panel [issue](https://github.com/IgniteUI/igniteui-angular/issues/307)
7. Conditional Cell Styling capability [issue](https://github.com/IgniteUI/igniteui-angular/issues/1079)
8. Typography Updates
9. Tooltip [issue](https://github.com/IgniteUI/igniteui-angular/issues/1710)
5. **[Done]**Quick Per-column Search in the igxGrid [issue](https://github.com/IgniteUI/igniteui-angular/issues/542)
6. **[Done]**Expandable Panel [issue](https://github.com/IgniteUI/igniteui-angular/issues/307)
7. **[Done]**Conditional Cell Styling capability [issue](https://github.com/IgniteUI/igniteui-angular/issues/1079)
8. **[Done]**Typography Updates
9. **[Done]**Tooltip [issue](https://github.com/IgniteUI/igniteui-angular/issues/1710)
10. **[Removed]** Vertical Tabs - material doesn't define vertical tabs
11. Row Editing with transactions [issue](https://github.com/IgniteUI/igniteui-angular/issues/566)
11. **[Done]** Row Editing with transactions (Batch editing) [issue](https://github.com/IgniteUI/igniteui-angular/issues/566)
12. **[Done]** Adding Disabled Dates and Special Dates options in igxCalander [issue](https://github.com/IgniteUI/igniteui-angular/issues/1980)
13. **[Done]** Drag and Drop Directive
14. Banner Component [issue](https://github.com/IgniteUI/igniteui-angular/issues/2672)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -286,8 +286,10 @@ describe('IgxTreeGrid - Key Board Navigation', () => {

UIInteractions.triggerKeyDownEvtUponElem('Enter', cell.nativeElement, true);
await wait(DEBOUNCETIME);
expect(cell.inEditMode).toBe(true);
fix.detectChanges();

cell = treeGrid.getCellByColumn(5, 'OnPTO');
expect(cell.inEditMode).toBe(true);
// Press tab key and verify the correct cell is opened
await TreeGridFunctions.moveEditableCellWithTab(fix, treeGrid, 5, 4, treeColumns);
});
Expand All @@ -310,7 +312,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
await testNavigationTab(fix, treeGrid, ['HireDate', 'ID', 'Name', 'Age', 'OnPTO']);
});

it('should change correct selected cell when there are pinned columns and press tab', async () => {
it('should change correct selected cell when there are pinned columns and press shift + tab', async () => {
treeGrid.getColumnByName('HireDate').pinned = true;
fix.detectChanges();

Expand Down Expand Up @@ -338,7 +340,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
TreeGridFunctions.verifyTreeGridCellSelected(treeGrid, cell);

UIInteractions.triggerKeyDownEvtUponElem('Space', cell.nativeElement, true);
await wait(30);
await wait(DEBOUNCETIME);
fix.detectChanges();

TreeGridFunctions.verifyDataRowsSelection(fix, [0], true);
Expand Down Expand Up @@ -620,7 +622,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
expect(treegrid.onSelection.emit).toHaveBeenCalledTimes(1);

cell.nativeElement.dispatchEvent(new KeyboardEvent('keydown', { key: 'End', ctrlKey: true }));
await wait(DEBOUNCETIME);
await wait(100);
fixture.detectChanges();

cell = treegrid.getCellByColumn(9, columns[columns.length - 1]);
Expand All @@ -629,7 +631,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
expect(treegrid.onSelection.emit).toHaveBeenCalledTimes(2);

cell.nativeElement.dispatchEvent(new KeyboardEvent('keydown', { key: 'Home', ctrlKey: true }));
await wait(DEBOUNCETIME);
await wait(100);
fixture.detectChanges();

cell = treegrid.getCellByColumn(0, columns[0]);
Expand All @@ -638,7 +640,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
expect(treegrid.onSelection.emit).toHaveBeenCalledTimes(3);

cell.nativeElement.dispatchEvent(new KeyboardEvent('keydown', { key: 'End', ctrlKey: true }));
await wait(DEBOUNCETIME);
await wait(100);
fixture.detectChanges();

cell = treegrid.getCellByColumn(9, columns[columns.length - 1]);
Expand Down Expand Up @@ -735,7 +737,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
(fixture, treegrid: IgxTreeGridComponent, cellRowIndex, cellColumn, rowsCount, rowsCountAfterCollapse) =>
new Promise(async (resolve, reject) => {
spyOn(treegrid.onRowToggle, 'emit').and.callThrough();
const cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
let cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
let rows = TreeGridFunctions.getAllRows(fixture);
expect(rows.length).toBe(rowsCount);

Expand All @@ -750,6 +752,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
await wait(DEBOUNCETIME);
fixture.detectChanges();

cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
rows = TreeGridFunctions.getAllRows(fixture);
expect(rows.length).toBe(rowsCountAfterCollapse);
TreeGridFunctions.verifyTreeRowHasCollapsedIcon(rows[cellRowIndex]);
Expand All @@ -761,6 +764,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
await wait(DEBOUNCETIME);
fixture.detectChanges();

cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
rows = TreeGridFunctions.getAllRows(fixture);
expect(rows.length).toBe(rowsCountAfterCollapse);
TreeGridFunctions.verifyTreeRowHasCollapsedIcon(rows[cellRowIndex]);
Expand All @@ -772,6 +776,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
await wait(DEBOUNCETIME);
fixture.detectChanges();

cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
rows = TreeGridFunctions.getAllRows(fixture);
expect(rows.length).toBe(rowsCount);
TreeGridFunctions.verifyTreeRowHasExpandedIcon(rows[cellRowIndex]);
Expand All @@ -783,6 +788,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
await wait(DEBOUNCETIME);
fixture.detectChanges();

cell = treegrid.getCellByColumn(cellRowIndex, cellColumn);
rows = TreeGridFunctions.getAllRows(fixture);
expect(rows.length).toBe(rowsCount);
TreeGridFunctions.verifyTreeRowHasExpandedIcon(rows[cellRowIndex]);
Expand Down Expand Up @@ -822,7 +828,7 @@ describe('IgxTreeGrid - Key Board Navigation', () => {

const testEditingNavigationShiftTab =
(fixture, treegrid: IgxTreeGridComponent, columns) => new Promise(async (resolve, reject) => {
const cell = treeGrid.getCellByColumn(2, columns[2]);
let cell = treeGrid.getCellByColumn(2, columns[2]);

cell.nativeElement.dispatchEvent(new Event('focus'));
await wait(DEBOUNCETIME);
Expand All @@ -833,6 +839,8 @@ describe('IgxTreeGrid - Key Board Navigation', () => {
UIInteractions.triggerKeyDownEvtUponElem('Enter', cell.nativeElement, true);
await wait(DEBOUNCETIME);
fixture.detectChanges();

cell = treeGrid.getCellByColumn(2, columns[2]);
expect(cell.inEditMode).toBe(true);

// Test on parent row
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -331,14 +331,15 @@ export class TreeGridFunctions {
firstColumnName: string,
nextColumnName: string,
moveRight: boolean = true) => new Promise(async (resolve, reject) => {
const cell = treeGrid.getCellByColumn(rowIndex, firstColumnName);
let cell = treeGrid.getCellByColumn(rowIndex, firstColumnName);
const keyboardEventKey = moveRight ? 'ArrowRight' : 'ArrowLeft';

UIInteractions.triggerKeyDownEvtUponElem(keyboardEventKey, cell.nativeElement, true);
await wait(DEBOUNCETIME);
fix.detectChanges();

const newCell = treeGrid.getCellByColumn(rowIndex, nextColumnName);
cell = treeGrid.getCellByColumn(rowIndex, firstColumnName);
if (cell !== undefined && cell !== null) {
TreeGridFunctions.verifyTreeGridCellSelected(treeGrid, cell, false);
}
Expand All @@ -361,14 +362,15 @@ export class TreeGridFunctions {
fix.detectChanges();

cell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex]);
if (cell !== undefined && cell !== null) {
TreeGridFunctions.verifyTreeGridCellSelected(treeGrid, cell, false);
}

if (columnIndex === columns.length - 1) {
newCell = treeGrid.getCellByColumn(rowIndex + 1, columns[0]);
} else {
newCell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex + 1]);
}
if (cell !== undefined && cell !== null) {
TreeGridFunctions.verifyTreeGridCellSelected(treeGrid, cell, false);
}
TreeGridFunctions.verifyTreeGridCellSelected(treeGrid, newCell);
expect(newCell.focused).toEqual(true);

Expand Down Expand Up @@ -415,15 +417,15 @@ export class TreeGridFunctions {
fix.detectChanges();

cell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex]);
if (cell !== undefined && cell !== null) {
expect(cell.inEditMode).toBe(false);
}

if (columnIndex === columns.length - 1) {
newCell = treeGrid.getCellByColumn(rowIndex + 1, columns[0]);
} else {
newCell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex + 1]);
}

if (cell !== undefined && cell !== null) {
expect(cell.inEditMode).toBe(false);
}
expect(newCell.inEditMode).toBe(true);
resolve();
})
Expand All @@ -441,15 +443,15 @@ export class TreeGridFunctions {
fix.detectChanges();

cell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex]);
if (cell !== undefined && cell !== null) {
expect(cell.inEditMode).toBe(false);
}

if (columnIndex === 0) {
newCell = treeGrid.getCellByColumn(rowIndex - 1, columns[columns.length - 1]);
} else {
newCell = treeGrid.getCellByColumn(rowIndex, columns[columnIndex - 1]);
}

if (cell !== undefined && cell !== null) {
expect(cell.inEditMode).toBe(false);
}
expect(newCell.inEditMode).toBe(true);
resolve();
})
Expand Down

0 comments on commit 8b6724a

Please sign in to comment.