fix(analytics): keep readable owner labels server-side
This commit is contained in:
@@ -49,6 +49,7 @@ test('injects one local same-origin tracker with page dimensions', () => {
|
||||
const html = '<!doctype html><html><head><title>Demo</title></head><body><h1>Demo</h1></body></html>';
|
||||
const out = injectMindSpaceAnalytics(html, {
|
||||
ownerId: 'user-123',
|
||||
ownerLabel: '张三',
|
||||
pageId: 'page-1',
|
||||
publicationId: 'pub-1',
|
||||
config: {
|
||||
@@ -65,7 +66,8 @@ test('injects one local same-origin tracker with page dimensions', () => {
|
||||
assert.match(out, /data-auto-track="false"/);
|
||||
assert.match(out, /page_id/);
|
||||
assert.match(out, /owner_segment/);
|
||||
assert.match(out, /owner_label/);
|
||||
assert.doesNotMatch(out, /owner_label/);
|
||||
assert.doesNotMatch(out, /张三/);
|
||||
assert.match(out, /page_click/);
|
||||
assert.match(out, /page_form_submit/);
|
||||
assert.match(out, /page_scroll_/);
|
||||
|
||||
Reference in New Issue
Block a user