Closed Bug 1901109 Opened 1 year ago Closed 1 year ago

PPA API - Add unit tests to the JS Module

Categories

(Core :: DOM: Core & HTML, task)

task

Tracking

()

RESOLVED FIXED
130 Branch
Tracking Status
firefox130 --- fixed

People

(Reporter: bbirdsong, Assigned: cbguder)

References

(Blocks 1 open bug)

Details

Attachments

(1 file, 1 obsolete file)

No description provided.
Summary: PPA API - Add additional unit tests to the JS Module → PPA API - Add unit tests to the JS Module
Assignee: nobody → bbirdsong
Status: NEW → ASSIGNED
Attachment #9406167 - Attachment description: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,simonf
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,simonf → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger
Assignee: bbirdsong → cbguder
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=mt,emilio,aleiserson,sfriedberger
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=mt,emilio,aleiserson,sfriedberger → WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger
Attachment #9406167 - Attachment description: WIP: Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=bgrins!,mt,emilio,aleiserson,sfriedberger → Bug 1901109 - Add initial unit tests for Private Attribution implementation. r=mt,emilio,aleiserson,simonf
Pushed by gleonard@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/1983386d307c Add initial unit tests for Private Attribution implementation. r=mt,simonf
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Regressions: 1904947
  • Allow mocking DAPTelemetrySender to test measurements without having
    to decrypt payloads
  • Allow mocking Date.now to test expiration conditions

Also:

  • Stop swallowing errors in DAPTelemetrySender
  • Correct typo loopbackDays -> lookbackDays

Original Revision: https://phabricator.services.mozilla.com/D212957

Attachment #9409769 - Flags: approval-mozilla-beta?

beta Uplift Approval Request

  • User impact if declined: Private Attribution trial on MDN would need to be delayed or undertaken without sufficient test coverage and error handling.
  • Code covered by automated testing: yes
  • Fix verified in Nightly: no
  • Needs manual QE test: no
  • Steps to reproduce for manual QE testing: None
  • Risk associated with taking this patch: Low
  • Explanation of risk level: It mostly adds unit tests and makes small tweaks to a feature that is not in active use.
  • String changes made/needed: None
  • Is Android affected?: no
Attachment #9409769 - Attachment is obsolete: true
Attachment #9409769 - Flags: approval-mozilla-beta?

Backed out for causing xpcshell failures on test_ppa.js.

[task 2024-06-26T21:01:01.073Z] 21:01:01     INFO -  TEST-START | dom/privateattribution/tests/xpcshell/test_ppa.js
[task 2024-06-26T21:01:01.528Z] 21:01:01  WARNING -  TEST-UNEXPECTED-FAIL | dom/privateattribution/tests/xpcshell/test_ppa.js | xpcshell return code: 0
[task 2024-06-26T21:01:01.528Z] 21:01:01     INFO -  TEST-INFO took 440ms
[task 2024-06-26T21:01:01.528Z] 21:01:01     INFO -  >>>>>>>
[task 2024-06-26T21:01:01.528Z] 21:01:01     INFO -  PID 996 | DLL blocklist was unable to intercept AppInit DLLs.
[task 2024-06-26T21:01:01.528Z] 21:01:01     INFO -  PID 996 | Couldn't convert chrome URL: chrome://branding/locale/brand.properties
[task 2024-06-26T21:01:01.529Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp:148
[task 2024-06-26T21:01:01.529Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: Failed to get directory to cache.: file /builds/worker/checkouts/gecko/security/sandbox/win/src/sandboxbroker/sandboxBroker.cpp:148
[task 2024-06-26T21:01:01.530Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: Couldn't get the user appdata directory. Crash events may not be produced.: file /builds/worker/checkouts/gecko/toolkit/crashreporter/nsExceptionHandler.cpp:2898
[task 2024-06-26T21:01:01.531Z] 21:01:01     INFO -  (xpcshell/head.js) | test MAIN run_test pending (1)
[task 2024-06-26T21:01:01.531Z] 21:01:01     INFO -  (xpcshell/head.js) | test run_next_test 0 pending (2)
[task 2024-06-26T21:01:01.531Z] 21:01:01     INFO -  (xpcshell/head.js) | test MAIN run_test finished (2)
[task 2024-06-26T21:01:01.531Z] 21:01:01     INFO -  running event loop
[task 2024-06-26T21:01:01.532Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: Could not get the program name for a cubeb stream.: 'NS_SUCCEEDED(rv)', file /builds/worker/checkouts/gecko/dom/media/CubebUtils.cpp:467
[task 2024-06-26T21:01:01.532Z] 21:01:01     INFO -  dom/privateattribution/tests/xpcshell/test_ppa.js | Starting setup
[task 2024-06-26T21:01:01.532Z] 21:01:01     INFO -  (xpcshell/head.js) | test pending (2)
[task 2024-06-26T21:01:01.533Z] 21:01:01     INFO -  (xpcshell/head.js) | test run_next_test 0 finished (2)
[task 2024-06-26T21:01:01.533Z] 21:01:01     INFO -  (xpcshell/head.js) | test run_next_test 1 pending (2)
[task 2024-06-26T21:01:01.533Z] 21:01:01     INFO -  (xpcshell/head.js) | test finished (2)
[task 2024-06-26T21:01:01.533Z] 21:01:01     INFO -  dom/privateattribution/tests/xpcshell/test_ppa.js | Starting testSuccessfulConversion
[task 2024-06-26T21:01:01.533Z] 21:01:01     INFO -  (xpcshell/head.js) | test testSuccessfulConversion pending (2)
[task 2024-06-26T21:01:01.534Z] 21:01:01     INFO -  (xpcshell/head.js) | test run_next_test 1 finished (2)
[task 2024-06-26T21:01:01.534Z] 21:01:01  WARNING -  TEST-UNEXPECTED-FAIL | dom/privateattribution/tests/xpcshell/test_ppa.js | testSuccessfulConversion - [testSuccessfulConversion : 189] "undefined" deepEqual {"task":{"id":"DSZGMFh26hBYXNaKvhL_N4AHA3P5lDn19on1vFPBxJM","time_precision":60,"measurement_type":"vecu8"},"measurement":[0,1,0,0,0],"timeout":30000,"reason":"conversion"}
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  D:/task_171943322661274/build/tests/xpcshell/tests/dom/privateattribution/tests/xpcshell/test_ppa.js:testSuccessfulConversion:189
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  D:\task_171943322661274\build\tests\xpcshell\head.js:_do_main:245
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  D:\task_171943322661274\build\tests\xpcshell\head.js:_execute_test:596
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  -e:null:1
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  exiting test
[task 2024-06-26T21:01:01.535Z] 21:01:01     INFO -  Unexpected exception NS_ERROR_ABORT:
[task 2024-06-26T21:01:01.536Z] 21:01:01     INFO -  _abort_failed_test@D:\task_171943322661274\build\tests\xpcshell\head.js:869:20
[task 2024-06-26T21:01:01.536Z] 21:01:01     INFO -  do_report_result@D:\task_171943322661274\build\tests\xpcshell\head.js:981:5
[task 2024-06-26T21:01:01.536Z] 21:01:01     INFO -  Assert<@D:\task_171943322661274\build\tests\xpcshell\head.js:70:21
[task 2024-06-26T21:01:01.536Z] 21:01:01     INFO -  Assert.prototype.report@resource://testing-common/Assert.sys.mjs:251:10
[task 2024-06-26T21:01:01.537Z] 21:01:01     INFO -  deepEqual@resource://testing-common/Assert.sys.mjs:331:8
[task 2024-06-26T21:01:01.537Z] 21:01:01     INFO -  testSuccessfulConversion@D:/task_171943322661274/build/tests/xpcshell/tests/dom/privateattribution/tests/xpcshell/test_ppa.js:189:10
[task 2024-06-26T21:01:01.537Z] 21:01:01     INFO -  _do_main@D:\task_171943322661274\build\tests\xpcshell\head.js:245:6
[task 2024-06-26T21:01:01.538Z] 21:01:01     INFO -  _execute_test@D:\task_171943322661274\build\tests\xpcshell\head.js:596:5
[task 2024-06-26T21:01:01.538Z] 21:01:01     INFO -  @-e:1:1
[task 2024-06-26T21:01:01.538Z] 21:01:01     INFO -  exiting test
[task 2024-06-26T21:01:01.539Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: NS_ENSURE_TRUE(inst) failed: file StaticComponents.cpp:12658
[task 2024-06-26T21:01:01.539Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: NS_ENSURE_TRUE(inst) failed: file StaticComponents.cpp:12658
[task 2024-06-26T21:01:01.540Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: OOPDeinit() without successful OOPInit(): file /builds/worker/checkouts/gecko/toolkit/crashreporter/nsExceptionHandler.cpp:3470
[task 2024-06-26T21:01:01.540Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: XPCOM object StringBuffer released from static ctor/dtor: file /builds/worker/checkouts/gecko/xpcom/base/nsTraceRefcnt.cpp:216
[task 2024-06-26T21:01:01.541Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: XPCOM object PerThreadData destroyed from static ctor/dtor: file /builds/worker/checkouts/gecko/xpcom/base/nsTraceRefcnt.cpp:216
[task 2024-06-26T21:01:01.541Z] 21:01:01     INFO -  PID 996 | [Parent 996, Main Thread] WARNING: XPCOM object SourceList destroyed from static ctor/dtor: file /builds/worker/checkouts/gecko/xpcom/base/nsTraceRefcnt.cpp:216
[task 2024-06-26T21:01:01.541Z] 21:01:01     INFO -  <<<<<<<
[task 2024-06-26T21:01:01.541Z] 21:01:01     INFO -  TEST-START | dom/streams/test/xpcshell/large-pipeto.js
Status: RESOLVED → REOPENED
Flags: needinfo?(cbguder)
Resolution: FIXED → ---
Pushed by gleonard@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/b6732c681a77 Add initial unit tests for Private Attribution implementation. r=mt,simonf
Status: REOPENED → RESOLVED
Closed: 1 year ago1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 130 Branch
Flags: needinfo?(cbguder)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: