| @@ 65-75 (lines=11) @@ | ||
| 62 | $this->assertTrue(count($sizes) > 1); |
|
| 63 | } |
|
| 64 | ||
| 65 | public function test_scale_down_with_max_width() { |
|
| 66 | $sourceFile = $this->createSourceFile(); |
|
| 67 | $imageObject = $this->createImageObject(); |
|
| 68 | ||
| 69 | $this->scaler->setMaxWidth(1000); |
|
| 70 | $sizes = $this->scaler->scale($sourceFile, $imageObject); |
|
| 71 | ||
| 72 | foreach ($sizes as $width => $height) { |
|
| 73 | $this->assertTrue($width < 1000); |
|
| 74 | } |
|
| 75 | } |
|
| 76 | ||
| 77 | public function test_scale_down_with_max_filesize() { |
|
| 78 | $sourceFile = $this->createSourceFile(); |
|
| @@ 68-78 (lines=11) @@ | ||
| 65 | $this->assertTrue(count($sizes) > 1); |
|
| 66 | } |
|
| 67 | ||
| 68 | public function test_scale_down_with_max_width() { |
|
| 69 | $sourceFile = $this->createSourceFile(); |
|
| 70 | $imageObject = $this->createImageObject(); |
|
| 71 | ||
| 72 | $this->scaler->setMaxWidth(1000); |
|
| 73 | $sizes = $this->scaler->scale($sourceFile, $imageObject); |
|
| 74 | ||
| 75 | foreach ($sizes as $width => $height) { |
|
| 76 | $this->assertTrue($width < 1000); |
|
| 77 | } |
|
| 78 | } |
|
| 79 | ||
| 80 | public function test_scale_down_with_include_source_disabled() { |
|
| 81 | $sourceFile = $this->createSourceFile(); |
|