Skip to content

Commit 666696d

Browse files
committed
Merge branch 'master' into cnd-parser
2 parents c992ab0 + 29f2091 commit 666696d

38 files changed

+2252
-277
lines changed

fixtures/10_Writing/add.xml

Lines changed: 40 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -60,16 +60,46 @@
6060
<sv:value>nt:folder</sv:value>
6161
</sv:property>
6262
</sv:node>
63-
<sv:node sv:name="testAddNodeWithUnregisteredNamespace">
64-
<sv:property sv:name="jcr:primaryType" sv:type="Name">
65-
<sv:value>nt:unstructured</sv:value>
66-
</sv:property>
67-
</sv:node>
68-
<sv:node sv:name="testAddPropertyWithUnregisteredNamespace">
69-
<sv:property sv:name="jcr:primaryType" sv:type="Name">
70-
<sv:value>nt:unstructured</sv:value>
71-
</sv:property>
72-
</sv:node>
63+
<sv:node sv:name="testAddNodeAutoNamedEmptyNamehint">
64+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
65+
<sv:value>nt:file</sv:value>
66+
</sv:property>
67+
<sv:node sv:name="jcr:content">
68+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
69+
<sv:value>nt:unstructured</sv:value>
70+
</sv:property>
71+
</sv:node>
72+
</sv:node>
73+
<sv:node sv:name="testAddNodeAutoNamedNullNamehint">
74+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
75+
<sv:value>nt:file</sv:value>
76+
</sv:property>
77+
<sv:node sv:name="jcr:content">
78+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
79+
<sv:value>nt:unstructured</sv:value>
80+
</sv:property>
81+
</sv:node>
82+
</sv:node>
83+
<sv:node sv:name="testAddNodeAutoNamedValidNamespaceNamehint">
84+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
85+
<sv:value>nt:file</sv:value>
86+
</sv:property>
87+
<sv:node sv:name="jcr:content">
88+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
89+
<sv:value>nt:unstructured</sv:value>
90+
</sv:property>
91+
</sv:node>
92+
</sv:node>
93+
<sv:node sv:name="testAddNodeWithUnregisteredNamespace">
94+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
95+
<sv:value>nt:unstructured</sv:value>
96+
</sv:property>
97+
</sv:node>
98+
<sv:node sv:name="testAddPropertyWithUnregisteredNamespace">
99+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
100+
<sv:value>nt:unstructured</sv:value>
101+
</sv:property>
102+
</sv:node>
73103
<sv:node sv:name="testAddPropertyOnUnstructured">
74104
<sv:property sv:name="jcr:primaryType" sv:type="Name">
75105
<sv:value>nt:unstructured</sv:value>

fixtures/10_Writing/clone.xml

Lines changed: 198 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,198 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<sv:node xmlns:crx="http://www.day.com/crx/1.0" xmlns:mix="http://www.jcp.org/jcr/mix/1.0" xmlns:nt="http://www.jcp.org/jcr/nt/1.0" xmlns:fn="http://www.w3.org/2005/xpath-functions" xmlns:fn_old="http://www.w3.org/2004/10/xpath-functions" xmlns:vlt="http://www.day.com/jcr/vault/1.0" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:jcr="http://www.jcp.org/jcr/1.0" xmlns:sv="http://www.jcp.org/jcr/sv/1.0" xmlns:rep="internal" sv:name="tests_write_manipulation_clone">
3+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
4+
<sv:value>nt:unstructured</sv:value>
5+
</sv:property>
6+
<sv:node sv:name="testWorkspaceClone">
7+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
8+
<sv:value>nt:unstructured</sv:value>
9+
</sv:property>
10+
<sv:node sv:name="referenceable">
11+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
12+
<sv:value>nt:unstructured</sv:value>
13+
</sv:property>
14+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
15+
<sv:value>mix:referenceable</sv:value>
16+
</sv:property>
17+
<sv:property sv:name="jcr:uuid" sv:type="String">
18+
<sv:value>842e61c0-09ab-42a9-87c0-308ccc90e6f6</sv:value>
19+
</sv:property>
20+
<sv:property sv:name="foo" sv:type="Name">
21+
<sv:value>bar_1</sv:value>
22+
</sv:property>
23+
<sv:node sv:name="cloneChild">
24+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
25+
<sv:value>nt:unstructured</sv:value>
26+
</sv:property>
27+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
28+
<sv:value>mix:referenceable</sv:value>
29+
</sv:property>
30+
<sv:property sv:name="jcr:uuid" sv:type="String">
31+
<sv:value>9da62173-d674-4413-87a4-8f538e033021</sv:value>
32+
</sv:property>
33+
<sv:property sv:name="fooChild" sv:type="Name">
34+
<sv:value>barChild</sv:value>
35+
</sv:property>
36+
</sv:node>
37+
</sv:node>
38+
<sv:node sv:name="referenceableRemoveExisting">
39+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
40+
<sv:value>nt:unstructured</sv:value>
41+
</sv:property>
42+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
43+
<sv:value>mix:referenceable</sv:value>
44+
</sv:property>
45+
<sv:property sv:name="jcr:uuid" sv:type="String">
46+
<sv:value>091d157f-dfaf-42eb-aedd-88183ff8fa3d</sv:value>
47+
</sv:property>
48+
<sv:property sv:name="foo" sv:type="Name">
49+
<sv:value>bar_2</sv:value>
50+
</sv:property>
51+
</sv:node>
52+
<sv:node sv:name="referenceableNoRemoveExisting_1">
53+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
54+
<sv:value>nt:unstructured</sv:value>
55+
</sv:property>
56+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
57+
<sv:value>mix:referenceable</sv:value>
58+
</sv:property>
59+
<sv:property sv:name="jcr:uuid" sv:type="String">
60+
<sv:value>99cce0f7-91fd-4dab-a9ed-ea939981d40b</sv:value>
61+
</sv:property>
62+
</sv:node>
63+
<sv:node sv:name="referenceableNoRemoveExisting_2">
64+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
65+
<sv:value>nt:unstructured</sv:value>
66+
</sv:property>
67+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
68+
<sv:value>mix:referenceable</sv:value>
69+
</sv:property>
70+
<sv:property sv:name="jcr:uuid" sv:type="String">
71+
<sv:value>471711ef-043b-4692-874b-f634932e79ba</sv:value>
72+
</sv:property>
73+
</sv:node>
74+
<sv:node sv:name="nonReferenceable">
75+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
76+
<sv:value>nt:unstructured</sv:value>
77+
</sv:property>
78+
<sv:property sv:name="foo" sv:type="Name">
79+
<sv:value>bar_3</sv:value>
80+
</sv:property>
81+
</sv:node>
82+
<sv:node sv:name="nonReferenceableRemoveExisting">
83+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
84+
<sv:value>nt:unstructured</sv:value>
85+
</sv:property>
86+
<sv:property sv:name="foo" sv:type="Name">
87+
<sv:value>bar_4</sv:value>
88+
</sv:property>
89+
</sv:node>
90+
<sv:node sv:name="nonReferenceableNoRemoveExisting">
91+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
92+
<sv:value>nt:unstructured</sv:value>
93+
</sv:property>
94+
</sv:node>
95+
</sv:node>
96+
<sv:node sv:name="testWorkspaceCorrespondingNode">
97+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
98+
<sv:value>nt:unstructured</sv:value>
99+
</sv:property>
100+
<sv:node sv:name="sourceNode">
101+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
102+
<sv:value>mix:referenceable</sv:value>
103+
</sv:property>
104+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
105+
<sv:value>nt:unstructured</sv:value>
106+
</sv:property>
107+
<sv:property sv:name="jcr:uuid" sv:type="String">
108+
<sv:value>a64bfa45-d5e1-4bf0-a739-1890da40579d</sv:value>
109+
</sv:property>
110+
</sv:node>
111+
<sv:node sv:name="nodeThatWillNotBeCloned">
112+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
113+
<sv:value>mix:referenceable</sv:value>
114+
</sv:property>
115+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
116+
<sv:value>nt:unstructured</sv:value>
117+
</sv:property>
118+
<sv:property sv:name="jcr:uuid" sv:type="String">
119+
<sv:value>e7c14901-aec8-4e9b-8e76-704197d24794</sv:value>
120+
</sv:property>
121+
</sv:node>
122+
</sv:node>
123+
<sv:node sv:name="testWorkspaceUpdateNode">
124+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
125+
<sv:value>nt:unstructured</sv:value>
126+
</sv:property>
127+
<sv:node sv:name="sourceNode">
128+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
129+
<sv:value>mix:referenceable</sv:value>
130+
</sv:property>
131+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
132+
<sv:value>nt:unstructured</sv:value>
133+
</sv:property>
134+
<sv:property sv:name="jcr:uuid" sv:type="String">
135+
<sv:value>c8996418-3fd9-407c-bfe6-faea6dcfbb40</sv:value>
136+
</sv:property>
137+
<sv:property sv:name="foo" sv:type="Name">
138+
<sv:value>bar_5</sv:value>
139+
</sv:property>
140+
<sv:node sv:name="cloneChild">
141+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
142+
<sv:value>nt:unstructured</sv:value>
143+
</sv:property>
144+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
145+
<sv:value>mix:referenceable</sv:value>
146+
</sv:property>
147+
<sv:property sv:name="jcr:uuid" sv:type="String">
148+
<sv:value>e7683690-0465-4aa8-87c6-f37a67d08469</sv:value>
149+
</sv:property>
150+
<sv:property sv:name="fooChild" sv:type="Name">
151+
<sv:value>barChild</sv:value>
152+
</sv:property>
153+
<sv:node sv:name="childOfChild">
154+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
155+
<sv:value>nt:unstructured</sv:value>
156+
</sv:property>
157+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
158+
<sv:value>mix:referenceable</sv:value>
159+
</sv:property>
160+
<sv:property sv:name="jcr:uuid" sv:type="String">
161+
<sv:value>7547cb47-3c13-4e23-b6d1-29685a434c88</sv:value>
162+
</sv:property>
163+
<sv:property sv:name="fooChildOfChild" sv:type="Name">
164+
<sv:value>barChildOfChild</sv:value>
165+
</sv:property>
166+
</sv:node>
167+
</sv:node>
168+
</sv:node>
169+
<sv:node sv:name="updateNoSuchWorkspace">
170+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
171+
<sv:value>mix:referenceable</sv:value>
172+
</sv:property>
173+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
174+
<sv:value>nt:unstructured</sv:value>
175+
</sv:property>
176+
<sv:property sv:name="jcr:uuid" sv:type="String">
177+
<sv:value>8cd0ab49-1e3d-4b92-bfe4-48bf3e5efdb3</sv:value>
178+
</sv:property>
179+
<sv:property sv:name="foo" sv:type="Name">
180+
<sv:value>bar_5</sv:value>
181+
</sv:property>
182+
</sv:node>
183+
<sv:node sv:name="updateSrcNotFound">
184+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
185+
<sv:value>mix:referenceable</sv:value>
186+
</sv:property>
187+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
188+
<sv:value>nt:unstructured</sv:value>
189+
</sv:property>
190+
<sv:property sv:name="jcr:uuid" sv:type="String">
191+
<sv:value>1d392bcb-3e49-4f0e-b0af-7c30ab838122</sv:value>
192+
</sv:property>
193+
<sv:property sv:name="foo" sv:type="Name">
194+
<sv:value>bar_6</sv:value>
195+
</sv:property>
196+
</sv:node>
197+
</sv:node>
198+
</sv:node>

fixtures/10_Writing/combinedmanipulations.xml

Lines changed: 88 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,21 @@
1313
</sv:property>
1414
</sv:node>
1515

16+
<sv:node sv:name="testAddAndRemoveProperty">
17+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
18+
<sv:value>nt:unstructured</sv:value>
19+
</sv:property>
20+
</sv:node>
21+
22+
<sv:node sv:name="testRemovePropertyAndNode">
23+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
24+
<sv:value>nt:unstructured</sv:value>
25+
</sv:property>
26+
<sv:property sv:name="prop" sv:type="String">
27+
<sv:value>Testvalue</sv:value>
28+
</sv:property>
29+
</sv:node>
30+
1631
<sv:node sv:name="testRemoveAndAdd">
1732
<sv:property sv:name="jcr:primaryType" sv:type="Name">
1833
<sv:value>nt:unstructured</sv:value>
@@ -58,6 +73,12 @@
5873
<sv:value>nt:unstructured</sv:value>
5974
</sv:property>
6075
</sv:node>
76+
<!-- this test will create its own node, but sanity checks test for this node to exist -->
77+
<sv:node sv:name="testRemoveAndAddAndRemoveToplevelNode">
78+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
79+
<sv:value>nt:unstructured</sv:value>
80+
</sv:property>
81+
</sv:node>
6182

6283
<sv:node sv:name="testRemoveAndMove">
6384
<sv:property sv:name="jcr:primaryType" sv:type="Name">
@@ -96,6 +117,72 @@
96117
</sv:node>
97118
</sv:node>
98119

120+
<sv:node sv:name="testRemoveMoveRemove">
121+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
122+
<sv:value>nt:unstructured</sv:value>
123+
</sv:property>
124+
<sv:node sv:name="src">
125+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
126+
<sv:value>nt:unstructured</sv:value>
127+
</sv:property>
128+
<sv:node sv:name="parent">
129+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
130+
<sv:value>nt:unstructured</sv:value>
131+
</sv:property>
132+
<sv:node sv:name="child">
133+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
134+
<sv:value>nt:unstructured</sv:value>
135+
</sv:property>
136+
</sv:node>
137+
</sv:node>
138+
</sv:node>
139+
</sv:node>
140+
141+
<sv:node sv:name="testMoveRemovepropertyMove">
142+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
143+
<sv:value>nt:unstructured</sv:value>
144+
</sv:property>
145+
<sv:node sv:name="src">
146+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
147+
<sv:value>nt:unstructured</sv:value>
148+
</sv:property>
149+
<sv:node sv:name="parent">
150+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
151+
<sv:value>nt:unstructured</sv:value>
152+
</sv:property>
153+
<sv:node sv:name="child">
154+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
155+
<sv:value>nt:unstructured</sv:value>
156+
</sv:property>
157+
<sv:property sv:name="test" sv:type="String">
158+
<sv:value>value</sv:value>
159+
</sv:property>
160+
</sv:node>
161+
</sv:node>
162+
</sv:node>
163+
</sv:node>
164+
165+
<sv:node sv:name="testLoadchildMovedNode">
166+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
167+
<sv:value>nt:unstructured</sv:value>
168+
</sv:property>
169+
<sv:node sv:name="src">
170+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
171+
<sv:value>nt:unstructured</sv:value>
172+
</sv:property>
173+
<sv:node sv:name="parent">
174+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
175+
<sv:value>nt:unstructured</sv:value>
176+
</sv:property>
177+
<sv:node sv:name="child">
178+
<sv:property sv:name="jcr:primaryType" sv:type="Name">
179+
<sv:value>nt:unstructured</sv:value>
180+
</sv:property>
181+
</sv:node>
182+
</sv:node>
183+
</sv:node>
184+
</sv:node>
185+
99186
<sv:node sv:name="testSessionHasPendingChanges">
100187
<sv:property sv:name="jcr:primaryType" sv:type="Name">
101188
<sv:value>nt:unstructured</sv:value>
@@ -195,7 +282,6 @@
195282
<sv:value>nt:unstructured</sv:value>
196283
</sv:property>
197284
</sv:node>
198-
199285
</sv:node>
200286

201287
<sv:node sv:name="testMoveSessionRefreshKeepChanges">
@@ -234,16 +320,7 @@
234320
</sv:property>
235321
</sv:node>
236322

237-
<sv:node sv:name="testNodeRefresh">
238-
<sv:property sv:name="jcr:primaryType" sv:type="Name">
239-
<sv:value>nt:unstructured</sv:value>
240-
</sv:property>
241-
<sv:property sv:name="prop" sv:type="String">
242-
<sv:value>Old</sv:value>
243-
</sv:property>
244-
</sv:node>
245-
246-
<sv:node sv:name="testNodeRefreshKeepChanges">
323+
<sv:node sv:name="testNodeRevert">
247324
<sv:property sv:name="jcr:primaryType" sv:type="Name">
248325
<sv:value>nt:unstructured</sv:value>
249326
</sv:property>

fixtures/10_Writing/copy.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@
2424
<sv:property sv:name="jcr:primaryType" sv:type="Name">
2525
<sv:value>nt:file</sv:value>
2626
</sv:property>
27+
<sv:property sv:name="jcr:mixinTypes" sv:type="Name">
28+
<sv:value>mix:referenceable</sv:value>
29+
</sv:property>
2730
<sv:property sv:name="jcr:created" sv:type="Date">
2831
<sv:value>2011-05-20T08:23:35.640+02:00</sv:value>
2932
</sv:property>

0 commit comments

Comments
 (0)