File tree 1 file changed +25
-2
lines changed
src/Symfony/Component/VarDumper/Tests/Caster
1 file changed +25
-2
lines changed Original file line number Diff line number Diff line change @@ -170,7 +170,10 @@ public function testCastModernText()
170
170
);
171
171
}
172
172
173
- public function testCastAttr ()
173
+ /**
174
+ * @requires PHP < 8.4
175
+ */
176
+ public function testCastAttrPriorToPhp84 ()
174
177
{
175
178
$ attr = new \DOMAttr ('attr ' , 'value ' );
176
179
@@ -187,6 +190,26 @@ public function testCastAttr()
187
190
);
188
191
}
189
192
193
+ /**
194
+ * @requires PHP 8.4
195
+ */
196
+ public function testCastAttr ()
197
+ {
198
+ $ attr = new \DOMAttr ('attr ' , 'value ' );
199
+
200
+ $ this ->assertDumpMatchesFormat (<<<'EODUMP'
201
+ DOMAttr {%A
202
+ +name: ? string
203
+ +specified: ? bool
204
+ +value: ? string
205
+ +ownerElement: ? ?DOMElement
206
+ +schemaTypeInfo: ? mixed
207
+ }
208
+ EODUMP,
209
+ $ attr
210
+ );
211
+ }
212
+
190
213
/**
191
214
* @requires PHP 8.4
192
215
*/
@@ -199,7 +222,7 @@ public function testCastModernAttr()
199
222
+name: ? string
200
223
+value: ? string
201
224
+ownerElement: ? ?Dom\Element
202
- +specified: true
225
+ +specified: ? bool
203
226
}
204
227
EODUMP,
205
228
$ attr
You can’t perform that action at this time.
0 commit comments