File tree 1 file changed +11
-1
lines changed
1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -382,11 +382,21 @@ public function testApplyTransformationToSrcset() {
382
382
/**
383
383
* @see https://github.com/indieweb/php-mf2/issues/84
384
384
* @group internet
385
+ *
386
+ * 2024-04-07: The final photo URL in this test changed over time.
387
+ * Updated it to only check that the final URL's hostname was correct,
388
+ * not the full photo URL.
385
389
*/
386
390
public function testRelativeURLResolvedWithFinalURL () {
387
391
$ mf = Mf2 \fetch ('http://aaron.pk/4Zn5 ' );
388
392
389
- $ this ->assertEquals ('https://aaronparecki.com/img/1240x0/2014/12/23/5/photo.jpeg ' , $ mf ['items ' ][0 ]['properties ' ]['photo ' ][0 ]);
393
+ $ this ->assertArrayHasKey ('photo ' , $ mf ['items ' ][0 ]['properties ' ]);
394
+
395
+ $ hostname = parse_url ($ mf ['items ' ][0 ]['properties ' ]['photo ' ][0 ], PHP_URL_HOST );
396
+ $ this ->assertEquals ('aaronparecki.com ' , $ hostname );
397
+
398
+ // previous assertion: not the photo URL changed over time
399
+ // $this->assertEquals('https://aaronparecki.com/img/1240x0/2014/12/23/5/photo.jpeg', $mf['items'][0]['properties']['photo'][0]);
390
400
}
391
401
392
402
public function testScriptTagContentsRemovedFromTextValue () {
You can’t perform that action at this time.
0 commit comments