Give tests easier means to spin up calendar services

RESOLVED FIXED in 5.0

Status

defect
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: Fallen, Assigned: Fallen)

Tracking

unspecified
Dependency tree / graph

Details

Attachments

(1 attachment, 1 obsolete attachment)

Right now we have a lot of tests that run either one of the calendar services, or manually spin up various services. It would be nice to simplify this a bit.

I noticed some of our tests are swallowing errors that timezones are not defined because they are not spinning up the timezone service.
Posted patch Fix - v1 (obsolete) β€” β€” Splinter Review
Geoff, can you take a look at this patch?
Attachment #8733544 - Flags: review?(geoff)
Comment on attachment 8733544 [details] [diff] [review]
Fix - v1

Review of attachment 8733544 [details] [diff] [review]:
-----------------------------------------------------------------

::: calendar/test/unit/test_storage.js
@@ +2,5 @@
>   * License, v. 2.0. If a copy of the MPL was not distributed with this
>   * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
>  
>  function run_test() {
> +    do_calendar_startup(run_next_test);

This doesn't apply properly, I think you must have another patch applied.

@@ +7,3 @@
>  }
>  
> +add_task(function testAttachRoundtrip() {

Should be add_test, no?
Attachment #8733544 - Flags: review?(geoff) → review+
(In reply to Geoff Lankow (:darktrojan) from comment #2)
> This doesn't apply properly, I think you must have another patch applied.

Yes, I have bug 1115667 applied, sorry about that!

> > +add_task(function testAttachRoundtrip() {
> 
> Should be add_test, no?
Good catch!
Posted patch Fix - v2 β€” β€” Splinter Review
Attachment #8733544 - Attachment is obsolete: true
Attachment #8741097 - Flags: review+
Please push this together with bug 1115667 (applies on top of the patches in that bug)
Keywords: checkin-needed

Updated

3 years ago
Depends on: 1115667

Comment 6

3 years ago
There was a slight conflict in test_items.js. Hopefully I fixed it correctly:
https://hg.mozilla.org/comm-central/rev/69b4c4164312c107137efa4fae17c63608fa30d1
Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → 5.0
This regressed Bug 1264782.
Depends on: 1264782
You need to log in before you can comment on or make changes to this bug.