Skip to content

Commit fc415b0

Browse files
committed
reenable tests now pecl is updated
and add a changelog note
1 parent 818aba2 commit fc415b0

File tree

5 files changed

+6
-13
lines changed

5 files changed

+6
-13
lines changed

CHANGELOG.md

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
# Changelog
22
All notable changes to `:vips` will be documented in this file.
33

4-
## 1.0.3-dev - 2017-06-06
4+
## 1.0.3 - 2017-06-06
55

66
### Added
77
- add Image::newInterpolator() [Kleis Auke Wolthuizen]
88
- implement array access interface [John Cupitt]
99
- add BlendMode and Image::composite [John Cupitt]
1010
- add Config::version() [John Cupitt]
11+
- add Image::newFromMemory() / Image::writeToMemory() [Kleis Auke Wolthuizen]
1112

1213
### Deprecated
1314
- Nothing

tests/ConfigTest.php

-4
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,8 @@ public function testVipsConcurrencySet()
3131

3232
public function testVipsVersion()
3333
{
34-
/* We can't test this on travis until we update the ext in pecl.
35-
*
3634
$version = Vips\Config::version();
3735
$this->assertEquals(preg_match("/\d+\.\d+\.\d+/", $version), 1);
38-
*
39-
*/
4036
}
4137
}
4238

tests/ConvenienceTest.php

-4
Original file line numberDiff line numberDiff line change
@@ -44,16 +44,12 @@ public function testVipsBandsplit()
4444

4545
public function testVipsComposite()
4646
{
47-
/* Enable this when we have vips_version() in pecl
48-
*
4947
if (version_compare(Vips\Config::version(), '8.6.0') >= 0) {
5048
$overlay = $this->image->add(20)->bandjoin(128);
5149
$overlay = $overlay->cast(Vips\BandFormat::UCHAR);
5250
$comp = $this->image->composite($overlay, Vips\BlendMode::OVER);
5351
$this->assertEquals($comp->getpoint(0, 0)[0], $this->pixel[0] + 10);
5452
}
55-
*
56-
*/
5753
}
5854

5955
public function testVipsAddConst()

tests/NewTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -110,14 +110,14 @@ public function testVipsNewInterpolator()
110110

111111
public function testVipsNewFromMemory()
112112
{
113-
/*$binaryStr = pack('C*', ...array_fill(0, 200, 0));
113+
$binaryStr = pack('C*', ...array_fill(0, 200, 0));
114114
$image = Vips\Image::newFromMemory($binaryStr, 20, 10, 1, Vips\BandFormat::UCHAR);
115115

116116
$this->assertEquals($image->width, 20);
117117
$this->assertEquals($image->height, 10);
118118
$this->assertEquals($image->format, Vips\BandFormat::UCHAR);
119119
$this->assertEquals($image->bands, 1);
120-
$this->assertEquals($image->avg(), 0);*/
120+
$this->assertEquals($image->avg(), 0);
121121
}
122122
}
123123

tests/WriteTest.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -62,11 +62,11 @@ public function testVipsWriteToBuffer()
6262

6363
public function testVipsWriteToMemory()
6464
{
65-
/*$binaryStr = pack('C*', ...array_fill(0, 200, 0));
65+
$binaryStr = pack('C*', ...array_fill(0, 200, 0));
6666
$image = Vips\Image::newFromMemory($binaryStr, 20, 10, 1, Vips\BandFormat::UCHAR);
6767
$memStr = $image->writeToMemory();
6868

69-
$this->assertEquals($binaryStr, $memStr);*/
69+
$this->assertEquals($binaryStr, $memStr);
7070
}
7171
}
7272

0 commit comments

Comments
 (0)