Skip to content
This repository has been archived by the owner on Dec 11, 2020. It is now read-only.

Commit

Permalink
Merge pull request #1186 from MyTeamName/master
Browse files Browse the repository at this point in the history
use secure https
  • Loading branch information
fzaninotto authored May 31, 2017
2 parents 5eb3a1e + f1ce3d8 commit df4572e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/Faker/Provider/Image.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ class Image extends Base
*/
public static function imageUrl($width = 640, $height = 480, $category = null, $randomize = true, $word = null, $gray = false)
{
$baseUrl = "http://lorempixel.com/";
$baseUrl = "https://lorempixel.com/";
$url = "{$width}/{$height}/";

if ($gray) {
Expand Down
8 changes: 4 additions & 4 deletions test/Faker/Provider/ImageTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,22 +8,22 @@ class ImageTest extends \PHPUnit_Framework_TestCase
{
public function testImageUrlUses640x680AsTheDefaultSize()
{
$this->assertRegExp('#^http://lorempixel.com/640/480/#', Image::imageUrl());
$this->assertRegExp('#^https://lorempixel.com/640/480/#', Image::imageUrl());
}

public function testImageUrlAcceptsCustomWidthAndHeight()
{
$this->assertRegExp('#^http://lorempixel.com/800/400/#', Image::imageUrl(800, 400));
$this->assertRegExp('#^https://lorempixel.com/800/400/#', Image::imageUrl(800, 400));
}

public function testImageUrlAcceptsCustomCategory()
{
$this->assertRegExp('#^http://lorempixel.com/800/400/nature/#', Image::imageUrl(800, 400, 'nature'));
$this->assertRegExp('#^https://lorempixel.com/800/400/nature/#', Image::imageUrl(800, 400, 'nature'));
}

public function testImageUrlAcceptsCustomText()
{
$this->assertRegExp('#^http://lorempixel.com/800/400/nature/Faker#', Image::imageUrl(800, 400, 'nature', false, 'Faker'));
$this->assertRegExp('#^https://lorempixel.com/800/400/nature/Faker#', Image::imageUrl(800, 400, 'nature', false, 'Faker'));
}

public function testImageUrlAddsARandomGetParameterByDefault()
Expand Down

0 comments on commit df4572e

Please sign in to comment.