Skip to content

Commit

Permalink
add a rule for nike (#479)
Browse files Browse the repository at this point in the history
  • Loading branch information
muodov authored Aug 19, 2024
1 parent 9178351 commit 5fb21c0
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
32 changes: 32 additions & 0 deletions rules/autoconsent/nike.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"name": "nike",
"vendorUrl": "https://nike.com",
"runContext": {
"urlPattern": "^https://(www\\.)?nike\\.com/"
},
"prehideSelectors": [],
"detectCmp": [
{
"exists": "[data-testid=cookie-dialog-root]"
}
],
"detectPopup": [
{
"visible": "[data-testid=cookie-dialog-root]"
}
],
"optIn": [
{
"waitForThenClick": "[data-testid=dialog-accept-button]"
}
],
"optOut": [
{
"waitForThenClick": "input[type=radio][id$=-declineLabel]",
"all": true
},
{
"waitForThenClick": "[data-testid=confirm-choice-button]"
}
]
}
5 changes: 5 additions & 0 deletions tests/nike.spec.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
import generateCMPTests from "../playwright/runner";

generateCMPTests('nike', [
'https://www.nike.com/',
]);

0 comments on commit 5fb21c0

Please sign in to comment.