Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/privacy.html
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ <h2>How we use your information</h2>
<li>To communicate with you about our products and services, if you have provided us with your
contact information.
</li>
<li>To comply with legal obligations.</li>
<li>To comply with legal obligations (GDPR).</li>
</ul>
<h2>Google Analytics</h2>
<p>We use Google Analytics to collect information about your use of our website. Google Analytics
Expand Down
20 changes: 20 additions & 0 deletions tests/mywebclass_privatePolicyGDPR.spec.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// @ts-check
const { test, expect } = require('@playwright/test')

test('Privacy policy should follow GDPR guidelines', async ({ page }) => {
// Navigate to the privacy policy page
await page.goto('http://localhost:3000/privacy.html')

// Check if the policy includes a statement about GDPR compliance
const policyText = await page.textContent('body')
const includesGDPRStatement = policyText.includes('GDPR')
expect(includesGDPRStatement).toBeTruthy()

// Check if the policy includes information about data
const includesDataProcessingInfo = policyText.includes('data')
expect(includesDataProcessingInfo).toBeTruthy()

// Check if the policy includes information about rights
const includesDataSubjectRights = policyText.includes('rights')
expect(includesDataSubjectRights).toBeTruthy()
})