actv 1.3.11 → 1.4.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/actv/article.rb +44 -53
- data/lib/actv/article_validator.rb +8 -0
- data/lib/actv/asset.rb +31 -27
- data/lib/actv/asset_factory.rb +15 -0
- data/lib/actv/asset_image.rb +0 -2
- data/lib/actv/asset_reference.rb +11 -0
- data/lib/actv/asset_validator.rb +31 -0
- data/lib/actv/author.rb +61 -0
- data/lib/actv/author_validator.rb +8 -0
- data/lib/actv/base.rb +12 -7
- data/lib/actv/client.rb +43 -28
- data/lib/actv/event.rb +9 -4
- data/lib/actv/event_validator.rb +8 -0
- data/lib/actv/version.rb +1 -1
- data/spec/actv/article_spec.rb +138 -28
- data/spec/actv/article_validator_spec.rb +23 -0
- data/spec/actv/asset_component_spec.rb +1 -2
- data/spec/actv/asset_factory_spec.rb +40 -0
- data/spec/actv/asset_reference_spec.rb +20 -0
- data/spec/actv/asset_spec.rb +51 -3
- data/spec/actv/asset_validator_spec.rb +8 -0
- data/spec/actv/author_spec.rb +80 -0
- data/spec/actv/author_validator_spec.rb +23 -0
- data/spec/actv/client_spec.rb +76 -5
- data/spec/actv/event_spec.rb +16 -8
- data/spec/actv/event_validator_spec.rb +23 -0
- data/spec/actv/evergreen_spec.rb +0 -10
- data/spec/fixtures/valid_article.json +181 -182
- data/spec/fixtures/valid_assets.json +394 -722
- data/spec/fixtures/valid_author.json +135 -0
- data/spec/fixtures/valid_event.json +178 -178
- data/spec/fixtures/valid_events.json +839 -0
- metadata +28 -3
@@ -0,0 +1,135 @@
|
|
1
|
+
{
|
2
|
+
"assetStatus": {
|
3
|
+
"assetStatusId": "2",
|
4
|
+
"assetStatusName": "VISIBLE"
|
5
|
+
},
|
6
|
+
"organization": {},
|
7
|
+
"place": {
|
8
|
+
"placeGuid": "0b794135-fa1a-41b4-90da-c29a381929c1",
|
9
|
+
"placeName": "Author",
|
10
|
+
"placeDsc": "",
|
11
|
+
"placeUrlAdr": "",
|
12
|
+
"addressLine1Txt": " ",
|
13
|
+
"addressLine2Txt": "",
|
14
|
+
"cityName": " ",
|
15
|
+
"stateProvinceCode": " ",
|
16
|
+
"localityName": "",
|
17
|
+
"postalCode": " ",
|
18
|
+
"countryName": "",
|
19
|
+
"countryCode": "",
|
20
|
+
"timezone": "",
|
21
|
+
"timezoneOffset": null,
|
22
|
+
"timezoneDST": null,
|
23
|
+
"latitude": "",
|
24
|
+
"longitude": "",
|
25
|
+
"directionsTxt": ""
|
26
|
+
},
|
27
|
+
"evergreenParentAsset": {},
|
28
|
+
"sourceSystem": {
|
29
|
+
"sourceSystemName": "Active.com Articles",
|
30
|
+
"legacyGuid": "CA4EA0B1-7377-470D-B20D-BF6BEA23F040",
|
31
|
+
"affiliate": "false"
|
32
|
+
},
|
33
|
+
"assetRootAsset": {},
|
34
|
+
"assetParentAsset": {},
|
35
|
+
"market": {},
|
36
|
+
"assetGuid": "34f4d344-97b0-4c2a-8920-f026f51742b2",
|
37
|
+
"assetName": "Jacquie Cattanach",
|
38
|
+
"assetDsc": "",
|
39
|
+
"alternateName": "",
|
40
|
+
"timezone": "",
|
41
|
+
"localTimeZoneId": "",
|
42
|
+
"timezoneAbb": "",
|
43
|
+
"timezoneName": "",
|
44
|
+
"currencyCd": "",
|
45
|
+
"localeCd": "",
|
46
|
+
"salesStartDate": null,
|
47
|
+
"salesEndDate": null,
|
48
|
+
"urlAdr": "",
|
49
|
+
"detailPageTemplateId": "",
|
50
|
+
"preferredUrlAdr": "",
|
51
|
+
"logoUrlAdr": "",
|
52
|
+
"activityStartDate": null,
|
53
|
+
"activityEndDate": null,
|
54
|
+
"donationUrlAdr": "",
|
55
|
+
"teamUrlAdr": "",
|
56
|
+
"homePageUrlAdr": "",
|
57
|
+
"registrationUrlAdr": "",
|
58
|
+
"registrantSearchUrlAdr": "",
|
59
|
+
"regReqMinAge": "",
|
60
|
+
"regReqMaxAge": "",
|
61
|
+
"regReqGenderCd": "",
|
62
|
+
"resultsUrlAdr": "",
|
63
|
+
"contactName": "",
|
64
|
+
"contactEmailAdr": "",
|
65
|
+
"contactPhone": "",
|
66
|
+
"contactTxt": "",
|
67
|
+
"showContact": "false",
|
68
|
+
"sorId": "",
|
69
|
+
"sorCreateDtm": null,
|
70
|
+
"sorCreateUserId": "",
|
71
|
+
"authorName": "",
|
72
|
+
"childIndex": "",
|
73
|
+
"publishDate": null,
|
74
|
+
"createdDate": "2015-06-15T20:42:05",
|
75
|
+
"modifiedDate": "2015-06-15T21:24:50",
|
76
|
+
"retryDate": "2015-06-15T17:34:46",
|
77
|
+
"retryCounter": "2",
|
78
|
+
"activityRecurrences": [],
|
79
|
+
"assetQuantity": {},
|
80
|
+
"assetLegacyData": {},
|
81
|
+
"assetTags": [],
|
82
|
+
"assetAttributes": [],
|
83
|
+
"assetPrices": [],
|
84
|
+
"assetDescriptions": [
|
85
|
+
{
|
86
|
+
"descriptionType": {
|
87
|
+
"descriptionTypeId": "28",
|
88
|
+
"descriptionTypeName": "authorFooter"
|
89
|
+
},
|
90
|
+
"description": "<div class=\"article-signature-block\"><div class=\"signature-block-photo\"><img alt=\"\" width=\"58\" height=\"58\" src=\"http://www.active.com/Assets/Running/Bios/jacquie-cattanach-bio.jpg\" /></div><div class=\"author-info\"><p><span class=\"author-link\"><a href=\"http://search.active.com/search?f=articles&v=list&k=%22jacquie+cattanach%22\" title=\"Jacquie Cattanach\">More Articles by Jacquie?</a></span><span class=\"author-name\">Jacquie Cattanach</span></p><p><span class=\"author-name\"></span></p><div class=\"author-text\">Jacquie Cattanach is an avid runner and triathlete whose biggest achievements have been 15 marathons and Ironman Canada. She has learned and experienced a lot of trials and tribulations along the way and she loves to write about them in her blog <a href=\"http://online-running-gear.com/blog/\" title=\"http://online-running-gear.com/blog/\" target=\"_blank\">Online Running Gear Blog</a>, where she also researches, reviews and recommends running products such as the <a href=\"http://online-running-gear.com/blog/running-gear-3/garmin-forerunner-405-review\" title=\"http://online-running-gear.com/blog/running-gear-3/garmin-forerunner-405-review\" target=\"_blank\">Garmin Forerunner 405</a> and the <a href=\"http://online-running-gear.com/blog/running-gear-3/p90x-review/\" title=\"http://online-running-gear.com/blog/running-gear-3/p90x-review/\" target=\"_blank\">P90X Workout Review</a>.</div></div></div>"
|
91
|
+
}
|
92
|
+
],
|
93
|
+
"assetChannels": [],
|
94
|
+
"assetMediaTypes": [
|
95
|
+
{
|
96
|
+
"sequence": "1",
|
97
|
+
"mediaType": {
|
98
|
+
"mediaTypeId": "327",
|
99
|
+
"mediaTypeName": "Features & News",
|
100
|
+
"mediaTypeDsc": ""
|
101
|
+
}
|
102
|
+
}
|
103
|
+
],
|
104
|
+
"assetImages": [],
|
105
|
+
"assetTopics": [],
|
106
|
+
"assetCategories": [
|
107
|
+
{
|
108
|
+
"sequence": "1",
|
109
|
+
"category": {
|
110
|
+
"categoryId": "290",
|
111
|
+
"categoryTaxonomy": "Person/Author",
|
112
|
+
"categoryName": "Author"
|
113
|
+
}
|
114
|
+
}
|
115
|
+
],
|
116
|
+
"assetMetaInterests": [],
|
117
|
+
"assetInterests": [],
|
118
|
+
"assetDeals": [],
|
119
|
+
"socialMedia": [],
|
120
|
+
"assetComponents": [],
|
121
|
+
"assetServiceHostName": "as-app-qa02",
|
122
|
+
"componentInUrlAdr": {},
|
123
|
+
"assetSeoUrls": [
|
124
|
+
{
|
125
|
+
"seoSystemName": "as3",
|
126
|
+
"statusCode": "true",
|
127
|
+
"urlAdr": "http://www.active.com/articles/jacquie-cattanach"
|
128
|
+
}
|
129
|
+
],
|
130
|
+
"overrideSeourlFlag": "false",
|
131
|
+
"activenetTopGraphic": {},
|
132
|
+
"evergreenAssetFlag": "false",
|
133
|
+
"evergreenAssets": [],
|
134
|
+
"assetReferences": []
|
135
|
+
}
|
@@ -1,188 +1,188 @@
|
|
1
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
|
-
|
2
|
+
"assetStatus": {
|
3
|
+
"assetStatusId": "2",
|
4
|
+
"assetStatusName": "VISIBLE",
|
5
|
+
"isSearchable": "true",
|
6
|
+
"isDeleted": "false",
|
7
|
+
"createdDate": "2012-05-17T18:19:49",
|
8
|
+
"modifiedDate": "2012-05-17T18:19:49"
|
9
|
+
},
|
10
|
+
"organization": {},
|
11
|
+
"place": {
|
12
|
+
"timezoneOffset": -5,
|
13
|
+
"timezoneDST": 1,
|
14
|
+
"placeGuid": "3993F0DC-2168-4497-943D-C64334CC8714",
|
15
|
+
"placeName": "Kingwood Park New Jersey",
|
16
|
+
"placeDsc": "",
|
17
|
+
"placeUrlAdr": "",
|
18
|
+
"addressLine1Txt": "200 Union Road",
|
19
|
+
"addressLine2Txt": "",
|
20
|
+
"cityName": "Frenchtown",
|
21
|
+
"stateProvinceCode": "",
|
22
|
+
"localityName": "New Jersey",
|
23
|
+
"postalCode": "08825",
|
24
|
+
"countryName": "United States",
|
25
|
+
"countryCode": "",
|
26
|
+
"latitude": "40.504792",
|
27
|
+
"longitude": "-75.001827",
|
28
|
+
"directionsTxt": "",
|
29
|
+
"geoPoint": {
|
30
|
+
"lat": "40.504792",
|
31
|
+
"lon": "-75.001827"
|
32
|
+
}
|
33
|
+
},
|
34
|
+
"evergreenAsset": {},
|
35
|
+
"dma": {
|
36
|
+
"dmaId": "52",
|
37
|
+
"dmaName": "New York"
|
38
|
+
},
|
39
|
+
"sourceSystem": {
|
40
|
+
"sourceSystemName": "RegCenter",
|
41
|
+
"legacyGuid": "EA4E860A-9DCD-4DAA-A7CA-4A77AD194F65"
|
42
|
+
},
|
43
|
+
"assetRootAsset": {},
|
44
|
+
"assetParentAsset": {},
|
45
|
+
"market": {},
|
46
|
+
"assetGuid": "BA288960-2718-4B20-B380-8F939596BB59",
|
47
|
+
"assetName": "Run Daddy Run 5k Race, 2 Mile Walk & Kids Fun Run",
|
48
|
+
"assetDsc": "The Run Daddy Run Event is the HCM Foundation way to bring the community together on Fathers Day Weekend to celebrate Fathers and their families. 100% of the proceeds will go to HCM service & scholarship programs.",
|
49
|
+
"alternateName": "",
|
50
|
+
"timezone": "",
|
51
|
+
"timezoneAbb": "",
|
52
|
+
"timezoneName": "",
|
53
|
+
"currencyCd": "",
|
54
|
+
"localeCd": "",
|
55
|
+
"salesStartDate": "2012-06-24T00:00:00",
|
56
|
+
"salesEndDate": "2012-07-24T00:00:00",
|
57
|
+
"urlAdr": "",
|
58
|
+
"detailPageTemplateId": "",
|
59
|
+
"preferredUrlAdr": "",
|
60
|
+
"logoUrlAdr": "",
|
61
|
+
"activityStartDate": "2012-06-24T00:00:00",
|
62
|
+
"activityStartTime": "9:00:00",
|
63
|
+
"activityEndDate": "2012-07-24T00:00:00",
|
64
|
+
"activityEndTime": "9:00:00",
|
65
|
+
"donationUrlAdr": "",
|
66
|
+
"teamUrlAdr": "",
|
67
|
+
"homePageUrlAdr": "http://www.hcmfoundation.org",
|
68
|
+
"registrationUrlAdr": "https://www.active.com/register/index.cfm?EVENT_ID=2028700",
|
69
|
+
"regReqMinAge": "",
|
70
|
+
"regReqMaxAge": "",
|
71
|
+
"regReqGenderCd": "",
|
72
|
+
"resultsUrlAdr": "",
|
73
|
+
"isRecurring": "false",
|
74
|
+
"contactName": "Mike Marsteller",
|
75
|
+
"contactEmailAdr": "hcmfund@gmail.com",
|
76
|
+
"contactPhone": "484-347-3993",
|
77
|
+
"contactTxt": "",
|
78
|
+
"showContact": "true",
|
79
|
+
"sorId": "",
|
80
|
+
"sorCreateDtm": null,
|
81
|
+
"sorCreateUserId": "",
|
82
|
+
"authorName": "",
|
83
|
+
"publishDate": null,
|
84
|
+
"createdDate": "2012-04-19T18:16:06",
|
85
|
+
"modifiedDate": "2012-05-17T18:29:18",
|
86
|
+
"activityRecurrences": [],
|
87
|
+
"assetQuantity": {},
|
88
|
+
"assetLegacyData": {
|
89
|
+
"assetTypeId": "",
|
90
|
+
"typeName": "",
|
91
|
+
"uploadSearchUrlAdr": "",
|
82
92
|
"authorName": "",
|
83
|
-
"
|
93
|
+
"onlineRegistration": "true",
|
94
|
+
"onlineDonation": "",
|
95
|
+
"onlineMembership": "",
|
96
|
+
"onlineMembershipCostAmt": "",
|
97
|
+
"costAmt": "",
|
98
|
+
"avgUserRatingTxt": "",
|
99
|
+
"estParticipantNb": "",
|
100
|
+
"maxTeamNb": "",
|
101
|
+
"minGuaranteedGameNb": "",
|
102
|
+
"multipleStartDate": "",
|
103
|
+
"genderRequirementTxt": "",
|
104
|
+
"participationCriteriaTxt": "",
|
105
|
+
"userCommentTxt": "",
|
106
|
+
"priceExtensionTxt": "",
|
107
|
+
"searchWeight": "",
|
108
|
+
"seoUrl": "http://www.active.com/running/frenchtown-nj/run-daddy-run-5k-race-2-mile-walk-and-kids-fun-run-2012",
|
109
|
+
"substitutionUrl": "2028700",
|
110
|
+
"trackbackUrl": "",
|
111
|
+
"eventCategories": "",
|
112
|
+
"isSearchable": "true",
|
84
113
|
"createdDate": "2012-04-19T18:16:06",
|
85
|
-
"modifiedDate": "2012-05-17T18:29:
|
86
|
-
|
87
|
-
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
"avgUserRatingTxt": "",
|
99
|
-
"estParticipantNb": "",
|
100
|
-
"maxTeamNb": "",
|
101
|
-
"minGuaranteedGameNb": "",
|
102
|
-
"multipleStartDate": "",
|
103
|
-
"genderRequirementTxt": "",
|
104
|
-
"participationCriteriaTxt": "",
|
105
|
-
"userCommentTxt": "",
|
106
|
-
"priceExtensionTxt": "",
|
107
|
-
"searchWeight": "",
|
108
|
-
"seoUrl": "http://www.active.com/running/frenchtown-nj/run-daddy-run-5k-race-2-mile-walk-and-kids-fun-run-2012",
|
109
|
-
"substitutionUrl": "2028700",
|
110
|
-
"trackbackUrl": "",
|
111
|
-
"eventCategories": "",
|
112
|
-
"isSearchable": "true",
|
113
|
-
"createdDate": "2012-04-19T18:16:06",
|
114
|
-
"modifiedDate": "2012-05-17T18:29:19"
|
114
|
+
"modifiedDate": "2012-05-17T18:29:19"
|
115
|
+
},
|
116
|
+
"assetTags": [],
|
117
|
+
"assetPrices": [{
|
118
|
+
"effectiveDate": "2012-08-03T06:59:00",
|
119
|
+
"priceAmt": "10",
|
120
|
+
"maxPriceAmt": "",
|
121
|
+
"minPriceAmt": ""
|
122
|
+
}],
|
123
|
+
"assetDescriptions": [{
|
124
|
+
"descriptionType": {
|
125
|
+
"descriptionTypeId": "1",
|
126
|
+
"descriptionTypeName": "PRIMARY"
|
115
127
|
},
|
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
|
-
|
164
|
-
"topicId": "26",
|
165
|
-
"topicTaxonomy": "Endurance/Duathlon",
|
166
|
-
"topicName": "Duathlon"
|
167
|
-
}
|
168
|
-
}],
|
169
|
-
"assetCategories": [
|
170
|
-
{
|
171
|
-
"category": {
|
172
|
-
"categoryName": "Races",
|
173
|
-
"categoryId": "22",
|
174
|
-
"categoryTaxonomy": "Event/Races"
|
175
|
-
},
|
128
|
+
"description": "The Run Daddy Run Event is the HCM Foundation way to bring the community together on Fathers Day Weekend to celebrate Fathers and their families. 100% of the proceeds will go to HCM service & scholarship programs."
|
129
|
+
}],
|
130
|
+
"assetChannels": [{
|
131
|
+
"sequence": "1",
|
132
|
+
"channel": {
|
133
|
+
"channelId": "1020",
|
134
|
+
"channelName": "Running",
|
135
|
+
"channelDsc": "Running"
|
136
|
+
}
|
137
|
+
}, {
|
138
|
+
"sequence": "2",
|
139
|
+
"channel": {
|
140
|
+
"channelId": "1148",
|
141
|
+
"channelName": "Running\\Cross Country",
|
142
|
+
"channelDsc": ""
|
143
|
+
}
|
144
|
+
}],
|
145
|
+
"assetMediaTypes": [{
|
146
|
+
"sequence": "2",
|
147
|
+
"mediaType": {
|
148
|
+
"mediaTypeId": "256",
|
149
|
+
"mediaTypeName": "Event\\5K",
|
150
|
+
"mediaTypeDsc": ""
|
151
|
+
}
|
152
|
+
}, {
|
153
|
+
"sequence": "1",
|
154
|
+
"mediaType": {
|
155
|
+
"mediaTypeId": "2",
|
156
|
+
"mediaTypeName": "Event",
|
157
|
+
"mediaTypeDsc": ""
|
158
|
+
}
|
159
|
+
}],
|
160
|
+
"assetImages": [],
|
161
|
+
"assetTopics": [{
|
162
|
+
"sequence": "3",
|
163
|
+
"topic": {
|
164
|
+
"topicId": "26",
|
165
|
+
"topicTaxonomy": "Endurance/Duathlon",
|
166
|
+
"topicName": "Duathlon"
|
167
|
+
}
|
168
|
+
}],
|
169
|
+
"assetCategories": [
|
170
|
+
{
|
171
|
+
"category": {
|
172
|
+
"categoryName": "Races",
|
173
|
+
"categoryId": "22",
|
174
|
+
"categoryTaxonomy": "Event/Races"
|
175
|
+
},
|
176
176
|
"sequence": "1"
|
177
177
|
}],
|
178
178
|
"assetMetaInterests": [],
|
179
179
|
"assetComponents": [
|
180
|
-
|
181
|
-
|
182
|
-
|
183
|
-
|
184
|
-
|
185
|
-
|
180
|
+
{
|
181
|
+
"assetGuid": "63e030f3-3df4-402c-9617-d37f6fb2c11b"
|
182
|
+
},
|
183
|
+
{
|
184
|
+
"assetGuid": "63e030f3-3df4-402c-9617-d37f6fb2c11c"
|
185
|
+
}
|
186
186
|
],
|
187
187
|
"assetServiceHostName": "asset-03"
|
188
|
-
}
|
188
|
+
}
|