Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

I.seeTraffic on post data traffic unexpectedly passes

Open
#3,920 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
35/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Stale
Tech stack
javascript, node.js, playwright
Domain
testing-qa

Research direction

Reproduce the POST request example with Playwright Helper's I.seeTraffic and the extra doesNotExist field. Start by tracing the I.seeTraffic requestPostData matching behavior; done means the intentionally mismatched request causes the test to fail rather than pass.

Written by the indexing model from the issue text.

Description

stale
What are you trying to achieve?

Test a POST request with I.seeTraffic (Playwright Helper) with an intentional fail.

For example at https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/POST
the existing POST request to https://developer.mozilla.org/pong/get with payload

{
   keywords: [],
   pongs: ["top", "side"
}

I use this test code:

Scenario('DEMO', async ({I}) => {
    I.amOnPage('https://developer.mozilla.org/en-US/docs/Web/HTTP/Methods/POST');
    await I.seeTraffic({
        url: 'https://developer.mozilla.org/pong/get', 
        name: 'POST Test', 
        timeout: 3,
        requestPostData: {
            keywords: [],
            pongs: ["side", "top"],
            doesNotExist: true
        }
    })
})
What do you get instead?

Test passes unexpectedly.

Details
  • CodeceptJS version: 3.5.6
  • NodeJS Version: 20.6.1
  • Operating System: MacOS latest version
  • Playwright: 1.38.1
Dominant language
JavaScript
Stars
4.2k
Forks
756
Avg merge
2d 9h
Merged PRs (30d)
16

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from codeceptjs/CodeceptJS

All issues in codeceptjs/CodeceptJS

Similar issues

More JavaScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.