Created
January 9, 2025 17:16
-
-
Save stepankuzmin/1aa7dc8a903e6e02df917ec34a3cafbb to your computer and use it in GitHub Desktop.
Summarize privacytests.org
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const d = await fetch('https://privacytests.org/index.json').then(r => r.json()); | |
let results = []; | |
for (const t of d.all_tests) { | |
let passed = 0; | |
for (const s1 in t.testResults) { | |
for (const s2 in t.testResults[s1]) { | |
if (t.testResults[s1][s2].passed) passed += 1; | |
} | |
} | |
console.log(t.browser, passed); | |
results.push([t.browser, passed]); | |
} | |
results.sort(([_0, a], [_1, b]) => a - b); | |
console.log(results); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment