govCMS / audit-site

govCMS site audit and remediation tool. Used to verify all sites built in, and for GovCMS SaaS meet the minimum requirements.
4 stars 4 forks source link

Confusing Google Analytics error message #18

Closed rooby closed 6 years ago

rooby commented 6 years ago

When the Google Analytics UA code is correctly configured, you still get this error:

Google Analytics is not configured correctly. Code snippet after is not correct - want , ga('create', 'UA-54970022-1', 'auto', {'name': 'govcms'}); ga('govcms.send', 'pageview', {'anonymizeIp': true}); but got ,

Tests to ensure the site is correctly configured google analytics.

tobybellwood commented 6 years ago

There are two elements to the GA code check - one to test that you have configured a code, and one to check that our ACSF hooks have inserted our code. The second case should only be tested on ACSF - again, another thing we're working on in the 2.x branch.