run-crank / cog-pardot

Pardot Cog for use with Crank
MIT License
0 stars 4 forks source link

New Step: Check list membership #34

Open iamEAP opened 4 years ago

iamEAP commented 4 years ago

What / Why

As a Crank user, I should be able to check that a Pardot Prospect is a member of a list and whether or not the Prospect is opted out.

Proposed Step Name: Check Pardot List Membership Proposed Step Expression: the (?<email>.+) pardot prospect should (?<optInOut>(be opted in to|be opted out of|not be a member of)) list (?<listId>.+)

Proposed Step Fields:

Proposed Step Records

Proposed Resolution

Outcomes

iamEAP commented 4 years ago

Some sample UAT scenarios:

scenario: Static List Membership
description: Proves list membership check works for static lists

tokens:
  test.email: static-pi@example.com

steps:
- step: Given I navigate to http://go.pardot.com/l/811013/2019-10-16/3mxyx
- step: And I fill out .qat-email-address input with {{test.email}}
- step: And I submit the form by clicking input[type="submit"]
- step: When I navigate to http://go.pardot.com/emailPreference/e/epc/811013/73l8a8WE9ADUxfXqsuccHNdSbUtyYnSPsF84xjhVW0g/411
- step: And I fill out input#list_20395 with 1
- step: And I submit the form by clicking input[type="submit"]
- step: Then the {{test.email}} Pardot Prospect should be opted in to list 20395
- step: Finally, delete the {{test.email}} Pardot Prospect
scenario: Dynamic List Membership
description: Proves list membership check works for dynamic lists

tokens:
  test.email: dynamic@example.com

steps:
- step: Given I create a Pardot Prospect
  data:
    prospect:
      email: '{{test.email}}'
      utm_campaign: DynamicSubscribe
- step: Then the {{test.email}} Pardot Prospect should be opted in to list 20397
- step: Finally, delete the {{test.email}} Pardot Prospect