Test automation for privacy manager actions

Testing platforms (like Selenium) enable your organization to automate and test end-user actions in your CMP message such as selecting an Accept All or Reject All button. In this article, we will cover how to identify the relevant element(s) of your privacy manager so that you can take an action on the element within your automated testing platform. 


Identify privacy manager button class

Every button that is added to your Sourcepoint privacy manager has an "action class" which denotes the Action Type assigned to the button in the privacy manager builder.

Screenshot 2024-09-17 at 3.10.34 PM.png

To find the action class for any button open the developer console of your browser and inspect a button in the privacy manager. The action class for the button will begin with sp_choice_type_.

Screenshot 2024-09-18 at 8.53.51 AM.png

Target the action class and take action on the element in your test automation.


Common privacy manager button classes 

For your convenience, we have compiled popular action classes for buttons that can be used in your privacy manager on a per regulation basis.

GDPR TCF / GDPR Standard / U.S. Privacy (Legacy)

Action Type Class
Accept All sp_choice_type_ACCEPT_ALL
Reject All sp_choice_type_REJECT_ALL
Save and Exit sp_choice_type_SAVE_AND_EXIT

U.S. Multi-State Privacy

Action Type Class
Accept All sp_choice_type_11
Reject All sp_choice_type_13
Save and Exit sp_choice_type_SE
Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.