-
Notifications
You must be signed in to change notification settings - Fork 32
/
cumulusci.yml
163 lines (152 loc) · 6.02 KB
/
cumulusci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
minimum_cumulusci_version: "3.16.0"
project:
name: Snowfakery
package:
api_version: "50.0"
dependencies:
- github: https://github.com/SalesforceFoundation/NPSP
sources:
npsp:
github: https://github.com/SalesforceFoundation/NPSP
tasks:
generate_sf_accounts:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/Account.recipe.yml
num_records: 100
num_records_tablename: Account
generate_sf_contacts:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/Contact.recipe.yml
num_records: 100
num_records_tablename: Contact
generate_sf_opportunities:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/Opportunity.recipe.yml
num_records: 100
num_records_tablename: Opportunity
generate_npsp_accounts:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/npsp/Account_npsp.recipe.yml
num_records: 100
num_records_tablename: Account
generate_npsp_contacts:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/npsp/Contact_npsp.recipe.yml
num_records: 100
num_records_tablename: Contact
generate_npsp_opportunities:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/npsp/Opportunity_npsp.recipe.yml
num_records: 100
num_records_tablename: Opportunity
generate_opportunity_contact_roles:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/OpportunityContactRole.recipe.yml
num_records: 100
num_records_tablename: Opportunity
generate_opportunities_and_contacts:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/OpportunityAndContact.recipe.yml
num_records: 100
num_records_tablename: Opportunity
generate_content_documents:
class_path: cumulusci.tasks.bulkdata.generate_and_load_data_from_yaml.GenerateAndLoadDataFromYaml
options:
generator_yaml: examples/salesforce/ContentVersion.recipe.yml
num_records: 10
num_records_tablename: Account
flows:
test_everything:
steps:
1:
task: generate_sf_accounts
2:
task: generate_sf_contacts
3:
task: generate_sf_opportunities
4:
flow: npsp:install_prod
5:
task: generate_npsp_accounts
6:
task: generate_npsp_contacts
7:
task: generate_npsp_opportunities
8:
task: generate_opportunity_contact_roles
9:
task: generate_opportunities_and_contacts
10:
task: generate_content_documents
contacts_for_accounts:
steps:
1:
task: query
options:
object: Account
query: select Id from Account
result_file: accounts.csv
2:
task: generate_and_load_from_yaml
options:
generator_yaml: examples/salesforce/ContactsForAccounts.recipe.yml
num_records: 100
num_records_tablename: Contact
person_accounts_and_community_users:
# only for use with the persons_and_communities org shape
steps:
1: # test assigning user profiles
task: query
options:
object: Profile
query: "select Id from Profile where Name='High Volume Customer Portal User'"
result_file: temp/temp_profiles.csv
2: # fixes "UNKNOWN_EXCEPTION, portal account owner must have a role"
task: execute_anon
options:
apex: >
UserRole ur = new UserRole(Name = 'CEO');
insert ur;
update new User(Id = UserInfo.getUserId(), UserRoleId = ur.Id);
3:
task: generate_and_load_from_yaml
options:
generator_yaml: examples/salesforce/person-accounts-plugin.recipe.yml
num_records: 5
num_records_tablename: User
test_upserts:
steps:
1:
task: snowfakery
options:
recipe: tests/upsert.yml
set_recently_viewed: False
2:
task: query
options:
object: Contact
query: "select Id,Email,Name from Contact where LastName='Bluth'"
result_file: /tmp/contacts_before.csv
3:
task: snowfakery
options:
recipe: tests/upsert-2.yml
set_recently_viewed: False
4:
task: query
options:
object: Contact
query: "select Id,Email,Name from Contact where LastName='Bluth'"
result_file: /tmp/contacts_after.csv
orgs:
scratch:
person_and_communities:
config_file: orgs/persons_and_communities.json