Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
max-ostapenko committed Jun 28, 2024
1 parent 2e15137 commit 9ab94b7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/technologies/g.json
Original file line number Diff line number Diff line change
Expand Up @@ -1705,7 +1705,7 @@
63
],
"cpe": "cpe:2.3:a:google:cloud_platform:*:*:*:*:*:*:*:*",
"description": "IT WORKS",
"description": "Google Cloud is a suite of cloud computing services.",
"icon": "Google Cloud.svg",
"website": "https://cloud.google.com"
},
Expand Down
7 changes: 2 additions & 5 deletions tests/wpt.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ const isDirectRun = require.main === module

const wptServer = process.env.WPT_SERVER
const wptApiKey = process.env.WPT_API_KEY
const PRnumber = parseInt(process.env.PR_NUMBER)
const prNumber = parseInt(process.env.PR_NUMBER)
const wpt = new WebPageTest(wptServer, wptApiKey)

/**
Expand All @@ -17,18 +17,15 @@ const wpt = new WebPageTest(wptServer, wptApiKey)
* @throws {Error} If the test run fails or the response status code is not 200.
*/
function runWPTTest(url) {
const options = { key: wptApiKey, wappalyzerPR: PRnumber }
const options = { key: wptApiKey, wappalyzerPR: prNumber }

console.log(`WPT test run for ${url} started`)
console.log('Options:', options)
return new Promise((resolve, reject) => {
wpt.runTestAndWait(url, options, (error, response) => {
if (error || response.statusCode !== 200) {
console.error(`WPT test run for ${url} failed:`)
console.error(error || response)
reject(error || response)
} else {
console.log(`WPT test run for ${url} completed`)
const technologies = {
detected: response.data.runs['1'].firstView.detected,
detected_apps: response.data.runs['1'].firstView.detected_apps,
Expand Down

0 comments on commit 9ab94b7

Please sign in to comment.