export class GridMock implements Xrm . Controls . Grid { private rows : Xrm . Collection . ItemCollection < Xrm . Controls . Grid . GridRow > ; private selectedRows : Xrm . Collection . ItemCollection < Xrm . Controls . Grid . GridRow > ; constructor ( rows , selectedRows ) { this . rows = rows ; this . selectedRows = selectedRows ; } public getRows ( ) { return this . rows ; } public getSelectedRows ( ) { return this . selectedRows ; } public getTotalRecordCount ( ) { return this . rows . getLength ( ) ; } }