<commit_before>import { expect, Page } from "@playwright/test";

export default class Index {
  constructor(private page: Page) {
  }

  async hasAdvancedSearchInputs(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`div.advanced-search *[name='${name}']`)).toBeVisible();
    }
  }

  async hasBulkButtons(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`div.box-bulk-actions :has-text("${name}")`).first()).toBeVisible();
    }
  }

  async hasColumns(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`[role=grid] th:has-text("${name}")`).first()).toBeVisible();
    }
  }

  async hasRowsOnTable(count: number) {
    await expect(this.page.locator('input[name="selection[]"]')).toHaveCount(count);
  }

  async hasTitle(title: string) {
    await expect(this.page).toHaveTitle(title);
  }

  async chooseNumberRowOnTable(number: number) {
    await this.page.locator('input[name="selection[]"]').nth(number - 1).highlight();
    await this.page.locator('input[name="selection[]"]').nth(number - 1).click();
  }

  async chooseRangeOfRowsOnTable(start: number, end: number) {
    for (let i = start - 1; i < end; i++) {
      await this.page.locator('input[name="selection[]"]').nth(i).highlight();<commit_msg>HP-934 remove hasTitle function from Index<commit_after>import { expect, Page } from "@playwright/test";

export default class Index {
  constructor(private page: Page) {
  }

  async hasAdvancedSearchInputs(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`div.advanced-search *[name='${name}']`)).toBeVisible();
    }
  }

  async hasBulkButtons(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`div.box-bulk-actions :has-text("${name}")`).first()).toBeVisible();
    }
  }

  async hasColumns(names: Array<string>) {
    for (const name of names) {
      await expect(this.page.locator(`[role=grid] th:has-text("${name}")`).first()).toBeVisible();
    }
  }

  async hasRowsOnTable(count: number) {
    await expect(this.page.locator('input[name="selection[]"]')).toHaveCount(count);
  }

  async chooseNumberRowOnTable(number: number) {
    await this.page.locator('input[name="selection[]"]').nth(number - 1).highlight();
    await this.page.locator('input[name="selection[]"]').nth(number - 1).click();
  }

  async chooseRangeOfRowsOnTable(start: number, end: number) {
    for (let i = start - 1; i < end; i++) {
      await this.page.locator('input[name="selection[]"]').nth(i).highlight();
{'fraction_non_alphanumeric': 0.18275075987841946, 'fraction_numerical': 0.003419452887537994, 'mean_word_length': 4.319191919191919, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '101019', 'n_tokens_mistral': 877, 'n_tokens_neox': 871, 'n_words': 157}