Skip to content

Commit a3a6fa9

Browse files
committed
Add ability to set true timestamp (close snowplow#484)
1 parent 278cf3a commit a3a6fa9

3 files changed

Lines changed: 5 additions & 4 deletions

File tree

src/js/out_queue.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,7 @@
315315
*/
316316
function encloseInPayloadDataEnvelope(events) {
317317
return json2.stringify({
318-
schema: 'iglu:com.snowplowanalytics.snowplow/payload_data/jsonschema/1-0-3',
318+
schema: 'iglu:com.snowplowanalytics.snowplow/payload_data/jsonschema/1-0-4',
319319
data: events
320320
});
321321
}

tests/integration/integration.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -153,10 +153,11 @@ define([
153153
}), 'A structured event should be detected');
154154
},
155155

156-
'Check an unstructured event was sent': function () {
156+
'Check an unstructured event with true timestamp was sent': function () {
157157
assert.isTrue(checkExistenceOfExpectedQuerystring({
158158
e: 'ue',
159-
ue_px: 'eyJzY2hlbWEiOiJpZ2x1OmNvbS5zbm93cGxvd2FuYWx5dGljcy5zbm93cGxvdy91bnN0cnVjdF9ldmVudC9qc29uc2NoZW1hLzEtMC0wIiwiZGF0YSI6eyJzY2hlbWEiOiJpZ2x1OmNvbS5hY21lX2NvbXBhbnkvdmlld2VkX3Byb2R1Y3QvanNvbnNjaGVtYS81LTAtMCIsImRhdGEiOnsicHJvZHVjdElkIjoiQVNPMDEwNDMifX19'
159+
ue_px: 'eyJzY2hlbWEiOiJpZ2x1OmNvbS5zbm93cGxvd2FuYWx5dGljcy5zbm93cGxvdy91bnN0cnVjdF9ldmVudC9qc29uc2NoZW1hLzEtMC0wIiwiZGF0YSI6eyJzY2hlbWEiOiJpZ2x1OmNvbS5hY21lX2NvbXBhbnkvdmlld2VkX3Byb2R1Y3QvanNvbnNjaGVtYS81LTAtMCIsImRhdGEiOnsicHJvZHVjdElkIjoiQVNPMDEwNDMifX19',
160+
ttm: '1477401868'
160161
}), 'An unstructured event should be detected');
161162
},
162163

tests/pages/integration-template.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@
4343
data: {
4444
productId: 'ASO01043'
4545
}
46-
});
46+
}, [], { type: 'ttm', value: 1477401868 });
4747

4848
var orderId = 'order-123';
4949

0 commit comments

Comments
 (0)