Closed Bug 1734792 Opened 2 years ago Closed 2 years ago

Perma fail comm/mailnews/compose/test/unit/test_longLines.js | testBodyWithLongLine - [testBodyWithLongLine : 55]


(MailNews Core :: Composition, defect, P5)


(thunderbird_esr91 unaffected, thunderbird94 unaffected)

95 Branch
Tracking Status
thunderbird_esr91 --- unaffected
thunderbird94 --- unaffected


(Reporter: intermittent-bug-filer, Assigned: TYLin)




(Keywords: intermittent-failure, regression)


(2 files)

Our test is failing in at least these three places, the space and one of the \r\ns is missing.

(I don't know anything about this test, I'm just reporting the failure. Somebody in #maildev may be able to help further if you need it.)

Flags: needinfo?(aethanyc)

Is this a perma fail or an intermittent? I could not see the test failed in the previous treeherder job

Bug 1733876 is likely to be the cause, and I don't expect the bug to change the behavior. However, gecko's test coverage to the plain text serializer is not great, I'd love to dig into more in some edge cases.

Flags: needinfo?(aethanyc) → needinfo?(geoff)

This is perma fail. I can reproduce this locally in latest mozilla-central via running ./mach test comm/mailnews/compose/test/unit/test_longLines.js.

Reverting bug 1733876 Part 3, 4, 5 fixed the testcase.

Assignee: nobody → aethanyc
Flags: needinfo?(geoff)
Summary: Intermittent comm/mailnews/compose/test/unit/test_longLines.js | testBodyWithLongLine - [testBodyWithLongLine : 55] → Perma fail comm/mailnews/compose/test/unit/test_longLines.js | testBodyWithLongLine - [testBodyWithLongLine : 55]

Bug 1733876 Part 3 wrongly changed the behavior because it failed to
consider that goodSpace may equals to -1 in the following forward search
while loop, which coincidentally is NS_LINEBREAKER_NEED_MORE_TEXT.

    while (goodSpace >= 0 && !nsCRT::IsAsciiSpace(mContent.CharAt(goodSpace))) {

Thus, when goodSpace == -1, we need to run the original forward search logic here.

The gtest is adapted from

The logic has nothing to do with LineBreaker, and it shouldn't rely on

Depends on D128002

Pushed by
Part 1 - Fix the logic where we break only at ascii spaces in FindWrapIndexForContent(). r=m_kato
Part 2 - Remove NS_LINEBREAKER_NEED_MORE_TEXT from the logic where break only at ascii spaces. r=m_kato
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch
You need to log in before you can comment on or make changes to this bug.