diff --git a/tests/Modifiers/ColorspaceModifierTest.php b/tests/Modifiers/ColorspaceModifierTest.php new file mode 100644 index 00000000..c57bdf11 --- /dev/null +++ b/tests/Modifiers/ColorspaceModifierTest.php @@ -0,0 +1,30 @@ +assertInstanceOf(ColorspaceInterface::class, $modifier->targetColorspace()); + + $modifier = new ColorspaceModifier('rgb'); + $this->assertInstanceOf(ColorspaceInterface::class, $modifier->targetColorspace()); + + $modifier = new ColorspaceModifier('cmyk'); + $this->assertInstanceOf(ColorspaceInterface::class, $modifier->targetColorspace()); + + $modifier = new ColorspaceModifier('test'); + $this->expectException(NotSupportedException::class); + $modifier->targetColorspace(); + } +} diff --git a/tests/Modifiers/PadModifierTest.php b/tests/Modifiers/PadModifierTest.php new file mode 100644 index 00000000..36c01ceb --- /dev/null +++ b/tests/Modifiers/PadModifierTest.php @@ -0,0 +1,24 @@ +shouldReceive('size')->andReturn($size); + $this->assertInstanceOf(SizeInterface::class, $modifier->getCropSize($image)); + } +}