Skip to content

[Bug] False throw of valid-title #295

Closed as not planned
Closed as not planned
@MartinPilny

Description

@MartinPilny

Let's have following test file

import { TestDetails, test } from '@playwright/test'

test.describe('Suite', () => {
  async function makeTest (testTitle: string, testOptions: TestDetails, urlPath: string) {
    test(testTitle, testOptions, async ({ page }) => {
      await page.goto('www.mywebsite.com/' + urlPath, { waitUntil: 'load' })
    })
  }

  makeTest('Test1', { tag: ['@smoke'] }, 'url_path_1')
  makeTest('Test2', { tag: ['@smoke'] }, 'url_path_2')
  makeTest('Test3', { tag: ['@smoke'] }, 'url_path_3')
})

I get this error
image
which is wrong regarding docs https://github.com/playwright-community/eslint-plugin-playwright/blob/main/docs/rules/valid-title.md

package version
eslint-plugin-playwright 1.6.2
@playwright/test 1.44.0

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions