{"version":3,"file":"table-testing.mjs","sources":["../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/table/testing/cell-harness.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/table/testing/row-harness.ts","../../../../../darwin_arm64-fastbuild-ST-fdfa778d11ba/bin/src/material/table/testing/table-harness.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n  ComponentHarnessConstructor,\n  ContentContainerComponentHarness,\n  HarnessPredicate,\n} from '@angular/cdk/testing';\nimport {CellHarnessFilters} from './table-harness-filters';\n\nexport abstract class _MatCellHarnessBase extends ContentContainerComponentHarness {\n  /** Gets the cell's text. */\n  async getText(): Promise<string> {\n    return (await this.host()).text();\n  }\n\n  /** Gets the name of the column that the cell belongs to. */\n  async getColumnName(): Promise<string> {\n    const host = await this.host();\n    const classAttribute = await host.getAttribute('class');\n\n    if (classAttribute) {\n      const prefix = 'mat-column-';\n      const name = classAttribute\n        .split(' ')\n        .map(c => c.trim())\n        .find(c => c.startsWith(prefix));\n\n      if (name) {\n        return name.split(prefix)[1];\n      }\n    }\n\n    throw Error('Could not determine column name of cell.');\n  }\n\n  protected static _getCellPredicate<T extends MatCellHarness>(\n    type: ComponentHarnessConstructor<T>,\n    options: CellHarnessFilters,\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(type, options)\n      .addOption('text', options.text, (harness, text) =>\n        HarnessPredicate.stringMatches(harness.getText(), text),\n      )\n      .addOption('columnName', options.columnName, (harness, name) =>\n        HarnessPredicate.stringMatches(harness.getColumnName(), name),\n      );\n  }\n}\n\n/** Harness for interacting with an Angular Material table cell. */\nexport class MatCellHarness extends _MatCellHarnessBase {\n  /** The selector for the host element of a `MatCellHarness` instance. */\n  static hostSelector = '.mat-mdc-cell:not(.mat-no-data-cell)';\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table cell with specific attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with(options: CellHarnessFilters = {}): HarnessPredicate<MatCellHarness> {\n    return _MatCellHarnessBase._getCellPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table header cell. */\nexport class MatHeaderCellHarness extends _MatCellHarnessBase {\n  /** The selector for the host element of a `MatHeaderCellHarness` instance. */\n  static hostSelector = '.mat-mdc-header-cell';\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table header cell with specific\n   * attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with(options: CellHarnessFilters = {}): HarnessPredicate<MatHeaderCellHarness> {\n    return _MatCellHarnessBase._getCellPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table footer cell. */\nexport class MatFooterCellHarness extends _MatCellHarnessBase {\n  /** The selector for the host element of a `MatFooterCellHarness` instance. */\n  static hostSelector = '.mat-mdc-footer-cell';\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table footer cell with specific\n   * attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with(options: CellHarnessFilters = {}): HarnessPredicate<MatFooterCellHarness> {\n    return _MatCellHarnessBase._getCellPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table cell inside a \"no data\" row. */\nexport class MatNoDataCellHarness extends _MatCellHarnessBase {\n  /** The selector for the host element of a `MatNoDataCellHarness` instance. */\n  static hostSelector = '.mat-no-data-cell';\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table cell with specific attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with(options: CellHarnessFilters = {}): HarnessPredicate<MatNoDataCellHarness> {\n    return _MatCellHarnessBase._getCellPredicate(this, options);\n  }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n  ComponentHarness,\n  ComponentHarnessConstructor,\n  HarnessPredicate,\n  parallel,\n} from '@angular/cdk/testing';\nimport {\n  _MatCellHarnessBase,\n  MatCellHarness,\n  MatFooterCellHarness,\n  MatHeaderCellHarness,\n  MatNoDataCellHarness,\n} from './cell-harness';\nimport {CellHarnessFilters, RowHarnessFilters} from './table-harness-filters';\n\n/** Text extracted from a table row organized by columns. */\nexport interface MatRowHarnessColumnsText {\n  [columnName: string]: string;\n}\n\nexport abstract class _MatRowHarnessBase<\n  CellType extends ComponentHarnessConstructor<Cell> & {\n    with: (options?: CellHarnessFilters) => HarnessPredicate<Cell>;\n  },\n  Cell extends _MatCellHarnessBase,\n> extends ComponentHarness {\n  protected abstract _cellHarness: CellType;\n\n  /** Gets a list of `MatCellHarness` for all cells in the row. */\n  async getCells(filter: CellHarnessFilters = {}): Promise<Cell[]> {\n    return this.locatorForAll(this._cellHarness.with(filter))();\n  }\n\n  /** Gets the text of the cells in the row. */\n  async getCellTextByIndex(filter: CellHarnessFilters = {}): Promise<string[]> {\n    const cells = await this.getCells(filter);\n    return parallel(() => cells.map(cell => cell.getText()));\n  }\n\n  /** Gets the text inside the row organized by columns. */\n  async getCellTextByColumnName(): Promise<MatRowHarnessColumnsText> {\n    const output: MatRowHarnessColumnsText = {};\n    const cells = await this.getCells();\n    const cellsData = await parallel(() =>\n      cells.map(cell => {\n        return parallel(() => [cell.getColumnName(), cell.getText()]);\n      }),\n    );\n    cellsData.forEach(([columnName, text]) => (output[columnName] = text));\n    return output;\n  }\n}\n\n/** Harness for interacting with an Angular Material table row. */\nexport class MatRowHarness extends _MatRowHarnessBase<typeof MatCellHarness, MatCellHarness> {\n  /** The selector for the host element of a `MatRowHarness` instance. */\n  static hostSelector = '.mat-mdc-row:not(.mat-mdc-no-data-row)';\n  protected _cellHarness = MatCellHarness;\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table row with specific attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with<T extends MatRowHarness>(\n    this: ComponentHarnessConstructor<T>,\n    options: RowHarnessFilters = {},\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table header row. */\nexport class MatHeaderRowHarness extends _MatRowHarnessBase<\n  typeof MatHeaderCellHarness,\n  MatHeaderCellHarness\n> {\n  /** The selector for the host element of a `MatHeaderRowHarness` instance. */\n  static hostSelector = '.mat-mdc-header-row';\n  protected _cellHarness = MatHeaderCellHarness;\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table header row with specific\n   * attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with<T extends MatHeaderRowHarness>(\n    this: ComponentHarnessConstructor<T>,\n    options: RowHarnessFilters = {},\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table footer row. */\nexport class MatFooterRowHarness extends _MatRowHarnessBase<\n  typeof MatFooterCellHarness,\n  MatFooterCellHarness\n> {\n  /** The selector for the host element of a `MatFooterRowHarness` instance. */\n  static hostSelector = '.mat-mdc-footer-row';\n  protected _cellHarness = MatFooterCellHarness;\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table footer row cell with specific\n   * attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with<T extends MatFooterRowHarness>(\n    this: ComponentHarnessConstructor<T>,\n    options: RowHarnessFilters = {},\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(this, options);\n  }\n}\n\n/** Harness for interacting with an Angular Material table \"no data\" row. */\nexport class MatNoDataRowHarness extends _MatRowHarnessBase<\n  typeof MatHeaderCellHarness,\n  MatHeaderCellHarness\n> {\n  /** The selector for the host element of a `MatNoDataRowHarness` instance. */\n  static hostSelector = '.mat-mdc-no-data-row';\n  protected _cellHarness = MatNoDataCellHarness;\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table header row with specific\n   * attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with<T extends MatNoDataRowHarness>(\n    this: ComponentHarnessConstructor<T>,\n    options: RowHarnessFilters = {},\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(this, options);\n  }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.dev/license\n */\n\nimport {\n  ComponentHarnessConstructor,\n  ContentContainerComponentHarness,\n  HarnessPredicate,\n  parallel,\n} from '@angular/cdk/testing';\nimport {\n  MatFooterRowHarness,\n  MatHeaderRowHarness,\n  MatNoDataRowHarness,\n  MatRowHarness,\n  MatRowHarnessColumnsText,\n} from './row-harness';\nimport {RowHarnessFilters, TableHarnessFilters} from './table-harness-filters';\n\n/** Text extracted from a table organized by columns. */\nexport interface MatTableHarnessColumnsText {\n  [columnName: string]: {\n    text: string[];\n    headerText: string[];\n    footerText: string[];\n  };\n}\n\n/** Harness for interacting with a mat-table in tests. */\nexport class MatTableHarness extends ContentContainerComponentHarness<string> {\n  /** The selector for the host element of a `MatTableHarness` instance. */\n  static hostSelector = '.mat-mdc-table';\n  _headerRowHarness = MatHeaderRowHarness;\n  _rowHarness = MatRowHarness;\n  private _footerRowHarness = MatFooterRowHarness;\n\n  /**\n   * Gets a `HarnessPredicate` that can be used to search for a table with specific attributes.\n   * @param options Options for narrowing the search\n   * @return a `HarnessPredicate` configured with the given options.\n   */\n  static with<T extends MatTableHarness>(\n    this: ComponentHarnessConstructor<T>,\n    options: TableHarnessFilters = {},\n  ): HarnessPredicate<T> {\n    return new HarnessPredicate(this, options);\n  }\n\n  /** Gets all the header rows in a table. */\n  async getHeaderRows(filter: RowHarnessFilters = {}): Promise<MatHeaderRowHarness[]> {\n    return this.locatorForAll(this._headerRowHarness.with(filter))();\n  }\n\n  /** Gets all the regular data rows in a table. */\n  async getRows(filter: RowHarnessFilters = {}): Promise<MatRowHarness[]> {\n    return this.locatorForAll(this._rowHarness.with(filter))();\n  }\n\n  /** Gets all the footer rows in a table. */\n  async getFooterRows(filter: RowHarnessFilters = {}): Promise<MatFooterRowHarness[]> {\n    return this.locatorForAll(this._footerRowHarness.with(filter))();\n  }\n\n  /** Gets the \"no data\" row in the table, if any. */\n  async getNoDataRow(filter: RowHarnessFilters = {}): Promise<MatNoDataRowHarness | null> {\n    return this.locatorForOptional(MatNoDataRowHarness.with(filter))();\n  }\n\n  /** Gets the text inside the entire table organized by rows. */\n  async getCellTextByIndex(): Promise<string[][]> {\n    const rows = await this.getRows();\n    return parallel(() => rows.map(row => row.getCellTextByIndex()));\n  }\n\n  /** Gets the text inside the entire table organized by columns. */\n  async getCellTextByColumnName(): Promise<MatTableHarnessColumnsText> {\n    const [headerRows, footerRows, dataRows] = await parallel(() => [\n      this.getHeaderRows(),\n      this.getFooterRows(),\n      this.getRows(),\n    ]);\n\n    const text: MatTableHarnessColumnsText = {};\n    const [headerData, footerData, rowsData] = await parallel(() => [\n      parallel(() => headerRows.map(row => row.getCellTextByColumnName())),\n      parallel(() => footerRows.map(row => row.getCellTextByColumnName())),\n      parallel(() => dataRows.map(row => row.getCellTextByColumnName())),\n    ]);\n\n    rowsData.forEach(data => {\n      Object.keys(data).forEach(columnName => {\n        const cellText = data[columnName];\n\n        if (!text[columnName]) {\n          text[columnName] = {\n            headerText: getCellTextsByColumn(headerData, columnName),\n            footerText: getCellTextsByColumn(footerData, columnName),\n            text: [],\n          };\n        }\n\n        text[columnName].text.push(cellText);\n      });\n    });\n\n    return text;\n  }\n}\n\n/** Extracts the text of cells only under a particular column. */\nfunction getCellTextsByColumn(rowsData: MatRowHarnessColumnsText[], column: string): string[] {\n  const columnTexts: string[] = [];\n\n  rowsData.forEach(data => {\n    Object.keys(data).forEach(columnName => {\n      if (columnName === column) {\n        columnTexts.push(data[columnName]);\n      }\n    });\n  });\n\n  return columnTexts;\n}\n"],"names":["_MatCellHarnessBase","ContentContainerComponentHarness","getText","host","text","getColumnName","classAttribute","getAttribute","prefix","name","split","map","c","trim","find","startsWith","Error","_getCellPredicate","type","options","HarnessPredicate","addOption","harness","stringMatches","columnName","MatCellHarness","hostSelector","with","MatHeaderCellHarness","MatFooterCellHarness","MatNoDataCellHarness","_MatRowHarnessBase","ComponentHarness","getCells","filter","locatorForAll","_cellHarness","getCellTextByIndex","cells","parallel","cell","getCellTextByColumnName","output","cellsData","forEach","MatRowHarness","MatHeaderRowHarness","MatFooterRowHarness","MatNoDataRowHarness","MatTableHarness","_headerRowHarness","_rowHarness","_footerRowHarness","getHeaderRows","getRows","getFooterRows","getNoDataRow","locatorForOptional","rows","row","headerRows","footerRows","dataRows","headerData","footerData","rowsData","data","Object","keys","cellText","headerText","getCellTextsByColumn","footerText","push","column","columnTexts"],"mappings":";;AAeM,MAAgBA,mBAAoB,SAAQC,gCAAgC,CAAA;EAEhF,MAAMC,OAAOA,GAAA;IACX,OAAO,CAAC,MAAM,IAAI,CAACC,IAAI,EAAE,EAAEC,IAAI,EAAE;AACnC;EAGA,MAAMC,aAAaA,GAAA;AACjB,IAAA,MAAMF,IAAI,GAAG,MAAM,IAAI,CAACA,IAAI,EAAE;IAC9B,MAAMG,cAAc,GAAG,MAAMH,IAAI,CAACI,YAAY,CAAC,OAAO,CAAC;AAEvD,IAAA,IAAID,cAAc,EAAE;MAClB,MAAME,MAAM,GAAG,aAAa;AAC5B,MAAA,MAAMC,IAAI,GAAGH,cAAc,CACxBI,KAAK,CAAC,GAAG,CAAA,CACTC,GAAG,CAACC,CAAC,IAAIA,CAAC,CAACC,IAAI,EAAE,CAAA,CACjBC,IAAI,CAACF,CAAC,IAAIA,CAAC,CAACG,UAAU,CAACP,MAAM,CAAC,CAAC;AAElC,MAAA,IAAIC,IAAI,EAAE;QACR,OAAOA,IAAI,CAACC,KAAK,CAACF,MAAM,CAAC,CAAC,CAAC,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