Bug 1127778 - fix paragraph reordering and add a test for it.

pull/21/head
Gijs Kruitbosch 9 years ago
parent 3bef3e7029
commit 3c277a1701

@ -679,8 +679,8 @@ Readability.prototype = {
div.id = "readability-page-1";
div.className = "page";
var children = articleContent.childNodes;
for (var i = 0; i < children.length; ++i) {
div.appendChild(children[i]);
while (children.length) {
div.appendChild(children[0]);
}
articleContent.appendChild(div);
}

@ -0,0 +1,27 @@
<div id="readability-page-1"
class="page">
<p id="first" class="">Regarding item# 11111, under sufficiently extreme conditions, quarks may
become deconfined and exist as free particles. In the course of asymptotic
freedom, the strong interaction becomes weaker at higher temperatures.
Eventually, color confinement would be lost and an extremely hot plasma
of freely moving quarks and gluons would be formed. This theoretical phase
of matter is called quark-gluon plasma.[81] The exact conditions needed
to give rise to this state are unknown and have been the subject of a great
deal of speculation and experimentation.</p>
<p id="second" class="">Regarding item# 22222, under sufficiently extreme conditions, quarks may
become deconfined and exist as free particles. In the course of asymptotic
freedom, the strong interaction becomes weaker at higher temperatures.
Eventually, color confinement would be lost and an extremely hot plasma
of freely moving quarks and gluons would be formed. This theoretical phase
of matter is called quark-gluon plasma.[81] The exact conditions needed
to give rise to this state are unknown and have been the subject of a great
deal of speculation and experimentation.</p>
<p id="third" class="">Regarding item# 33333, under sufficiently extreme conditions, quarks may
become deconfined and exist as free particles. In the course of asymptotic
freedom, the strong interaction becomes weaker at higher temperatures.
Eventually, color confinement would be lost and an extremely hot plasma
of freely moving quarks and gluons would be formed. This theoretical phase
of matter is called quark-gluon plasma.[81] The exact conditions needed
to give rise to this state are unknown and have been the subject of a great
deal of speculation and experimentation.</p>
</div>

@ -0,0 +1,9 @@
<html>
<body>
<br id="br1">
<p id="first">Regarding item# 11111, under sufficiently extreme conditions, quarks may become deconfined and exist as free particles. In the course of asymptotic freedom, the strong interaction becomes weaker at higher temperatures. Eventually, color confinement would be lost and an extremely hot plasma of freely moving quarks and gluons would be formed. This theoretical phase of matter is called quark-gluon plasma.[81] The exact conditions needed to give rise to this state are unknown and have been the subject of a great deal of speculation and experimentation.</p>
<p id="second">Regarding item# 22222, under sufficiently extreme conditions, quarks may become deconfined and exist as free particles. In the course of asymptotic freedom, the strong interaction becomes weaker at higher temperatures. Eventually, color confinement would be lost and an extremely hot plasma of freely moving quarks and gluons would be formed. This theoretical phase of matter is called quark-gluon plasma.[81] The exact conditions needed to give rise to this state are unknown and have been the subject of a great deal of speculation and experimentation.</p>
<p id="third">Regarding item# 33333, under sufficiently extreme conditions, quarks may become deconfined and exist as free particles. In the course of asymptotic freedom, the strong interaction becomes weaker at higher temperatures. Eventually, color confinement would be lost and an extremely hot plasma of freely moving quarks and gluons would be formed. This theoretical phase of matter is called quark-gluon plasma.[81] The exact conditions needed to give rise to this state are unknown and have been the subject of a great deal of speculation and experimentation.</p>
<br id="br2">
</body>
</html>
Loading…
Cancel
Save