File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -257,10 +257,15 @@ private function run_send_mails() {
257
257
* @param object|array $actual
258
258
*/
259
259
private function assert_matches_properties ($ expected , $ actual ) {
260
+ global $ CFG ;
260
261
$ expected = (array )$ expected ;
261
262
$ actual = (object )$ actual ;
262
263
foreach ($ expected as $ key => $ value ) {
263
- $ this ->assertObjectHasProperty ($ key , $ actual , "Failed asserting that attribute ' $ key' exists. " );
264
+ if ($ CFG ->branch >= 404 ) {
265
+ $ this ->assertObjectHasProperty ($ key , $ actual , "Failed asserting that attribute ' $ key' exists. " );
266
+ } else {
267
+ $ this ->assertObjectHasAttribute ($ key , $ actual , "Failed asserting that attribute ' $ key' exists. " );
268
+ }
264
269
$ this ->assertEquals ($ value , $ actual ->$ key , "Failed asserting that \$obj-> $ key ' " . $ actual ->$ key . "' equals ' $ value' " );
265
270
}
266
271
}
You can’t perform that action at this time.
0 commit comments