Skip to content

Commit b7475c0

Browse files
committed
test: Add test failure
1 parent 9e3c631 commit b7475c0

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

tests/Uri/Retrievers/FileGetContentsTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,15 @@ public function testContentType()
5959
$this->assertTrue($fetchContentType->invoke($res, array('Content-Type: application/json')));
6060
$this->assertFalse($fetchContentType->invoke($res, array('X-Some-Header: whateverValue')));
6161
}
62+
63+
public function testCanHandleHttp301PermanentRedirect()
64+
{
65+
$res = new FileGetContents();
66+
67+
$res->retrieve('http://asyncapi.com/definitions/2.0.0/asyncapi.json');
68+
69+
$this->assertSame('application/schema+json', $res->getContentType());
70+
}
6271
}
6372
}
6473

0 commit comments

Comments
 (0)