Skip to content

Commit e90b18b

Browse files
committed
Repeat the mutation tests but with the blocking/ignored nodes already in the DOM/mirror prior to mutation processing
1 parent 9666d32 commit e90b18b

9 files changed

+975
-3
lines changed
Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<body>
4+
<div id="with-blocked"
5+
><div
6+
class="rr-block"
7+
></div></div>
8+
<div id="with-comment"
9+
><!--
10+
slimdom ignored
11+
--></div>
12+
</body>
13+
</html>
Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
[
2+
{
3+
"type": 2,
4+
"data": {
5+
"node": {
6+
"type": 0,
7+
"childNodes": [
8+
{
9+
"type": 1,
10+
"name": "html",
11+
"publicId": "",
12+
"systemId": "",
13+
"id": 2
14+
},
15+
{
16+
"type": 2,
17+
"tagName": "html",
18+
"attributes": {},
19+
"childNodes": [
20+
{
21+
"type": 2,
22+
"tagName": "head",
23+
"attributes": {},
24+
"childNodes": [
25+
{
26+
"type": 2,
27+
"tagName": "script",
28+
"attributes": {
29+
"type": "text/javascript"
30+
},
31+
"childNodes": [
32+
{
33+
"type": 3,
34+
"textContent": "SCRIPT_PLACEHOLDER",
35+
"id": 6
36+
}
37+
],
38+
"id": 5
39+
}
40+
],
41+
"id": 4
42+
},
43+
{
44+
"type": 2,
45+
"tagName": "body",
46+
"attributes": {},
47+
"childNodes": [
48+
{
49+
"type": 3,
50+
"textContent": "\n ",
51+
"id": 8
52+
},
53+
{
54+
"type": 2,
55+
"tagName": "div",
56+
"attributes": {
57+
"id": "with-blocked"
58+
},
59+
"childNodes": [
60+
{
61+
"type": 2,
62+
"tagName": "div",
63+
"attributes": {
64+
"class": "rr-block",
65+
"rr_width": "1904px",
66+
"rr_height": "0px"
67+
},
68+
"childNodes": [],
69+
"id": 10
70+
}
71+
],
72+
"id": 9
73+
},
74+
{
75+
"type": 3,
76+
"textContent": "\n ",
77+
"id": 11
78+
},
79+
{
80+
"type": 2,
81+
"tagName": "div",
82+
"attributes": {
83+
"id": "with-comment"
84+
},
85+
"childNodes": [],
86+
"id": 12
87+
},
88+
{
89+
"type": 3,
90+
"textContent": "\n \n\n",
91+
"id": 13
92+
}
93+
],
94+
"id": 7
95+
}
96+
],
97+
"id": 3
98+
}
99+
],
100+
"id": 1
101+
},
102+
"initialOffset": {
103+
"left": 0,
104+
"top": 0
105+
}
106+
}
107+
},
108+
{
109+
"type": 3,
110+
"data": {
111+
"source": 0,
112+
"texts": [],
113+
"attributes": [],
114+
"removes": [],
115+
"adds": [
116+
{
117+
"parentId": 9,
118+
"nextId": 10,
119+
"node": {
120+
"type": 2,
121+
"tagName": "div",
122+
"attributes": {},
123+
"childNodes": [],
124+
"id": 14
125+
}
126+
}
127+
]
128+
}
129+
}
130+
]
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
[
2+
{
3+
"type": 3,
4+
"data": {
5+
"source": 0,
6+
"texts": [],
7+
"attributes": [],
8+
"removes": [],
9+
"adds": [
10+
{
11+
"parentId": 7,
12+
"nextId": null,
13+
"node": {
14+
"type": 2,
15+
"tagName": "div",
16+
"attributes": {},
17+
"childNodes": [],
18+
"id": 9
19+
}
20+
},
21+
{
22+
"parentId": 9,
23+
"nextId": null,
24+
"node": {
25+
"type": 2,
26+
"tagName": "div",
27+
"attributes": {
28+
"class": "rr-block",
29+
"rr_width": "1904px",
30+
"rr_height": "0px"
31+
},
32+
"childNodes": [],
33+
"id": 10
34+
}
35+
},
36+
{
37+
"parentId": 9,
38+
"nextId": 10,
39+
"node": {
40+
"type": 2,
41+
"tagName": "div",
42+
"attributes": {},
43+
"childNodes": [],
44+
"id": 11
45+
}
46+
}
47+
]
48+
}
49+
}
50+
]
Lines changed: 130 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,130 @@
1+
[
2+
{
3+
"type": 2,
4+
"data": {
5+
"node": {
6+
"type": 0,
7+
"childNodes": [
8+
{
9+
"type": 1,
10+
"name": "html",
11+
"publicId": "",
12+
"systemId": "",
13+
"id": 2
14+
},
15+
{
16+
"type": 2,
17+
"tagName": "html",
18+
"attributes": {},
19+
"childNodes": [
20+
{
21+
"type": 2,
22+
"tagName": "head",
23+
"attributes": {},
24+
"childNodes": [
25+
{
26+
"type": 2,
27+
"tagName": "script",
28+
"attributes": {
29+
"type": "text/javascript"
30+
},
31+
"childNodes": [
32+
{
33+
"type": 3,
34+
"textContent": "SCRIPT_PLACEHOLDER",
35+
"id": 6
36+
}
37+
],
38+
"id": 5
39+
}
40+
],
41+
"id": 4
42+
},
43+
{
44+
"type": 2,
45+
"tagName": "body",
46+
"attributes": {},
47+
"childNodes": [
48+
{
49+
"type": 3,
50+
"textContent": "\n ",
51+
"id": 8
52+
},
53+
{
54+
"type": 2,
55+
"tagName": "div",
56+
"attributes": {
57+
"id": "with-blocked"
58+
},
59+
"childNodes": [
60+
{
61+
"type": 2,
62+
"tagName": "div",
63+
"attributes": {
64+
"class": "rr-block",
65+
"rr_width": "1904px",
66+
"rr_height": "0px"
67+
},
68+
"childNodes": [],
69+
"id": 10
70+
}
71+
],
72+
"id": 9
73+
},
74+
{
75+
"type": 3,
76+
"textContent": "\n ",
77+
"id": 11
78+
},
79+
{
80+
"type": 2,
81+
"tagName": "div",
82+
"attributes": {
83+
"id": "with-comment"
84+
},
85+
"childNodes": [],
86+
"id": 12
87+
},
88+
{
89+
"type": 3,
90+
"textContent": "\n \n\n",
91+
"id": 13
92+
}
93+
],
94+
"id": 7
95+
}
96+
],
97+
"id": 3
98+
}
99+
],
100+
"id": 1
101+
},
102+
"initialOffset": {
103+
"left": 0,
104+
"top": 0
105+
}
106+
}
107+
},
108+
{
109+
"type": 3,
110+
"data": {
111+
"source": 0,
112+
"texts": [],
113+
"attributes": [],
114+
"removes": [],
115+
"adds": [
116+
{
117+
"parentId": 9,
118+
"nextId": null,
119+
"node": {
120+
"type": 2,
121+
"tagName": "div",
122+
"attributes": {},
123+
"childNodes": [],
124+
"id": 14
125+
}
126+
}
127+
]
128+
}
129+
}
130+
]

0 commit comments

Comments
 (0)