Add headerIsPresent assertion

Created on 8 June 2023, about 1 year ago

Add for Cypress and Playwright.

  theHeaderContains: async ([response, headerValue, shouldContain, ...headers]) => {
    for (const header of headers) {
      if (shouldContain) {
        expect(await response.headerValue(headerValue)).toContain(header);
      } else {
        expect(await response.headerValue(headerValue)).not.toContain(header);
      }
    }
  },

h/t Petar Basic of Drunomics:
https://github.com/drunomics/playwright-drupal-starter/blob/main/tests/playwright/tests/helpers/test-methods.js

πŸ“Œ Task
Status

Active

Component

Code

Created by

πŸ‡ΊπŸ‡ΈUnited States aangel

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024