Skip to content

Commit b05fdf0

Browse files
committed
Merge branch 'develop'
2 parents 4a2d747 + 88b49bc commit b05fdf0

1 file changed

Lines changed: 15 additions & 15 deletions

File tree

tests/unitary-stream.php

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,18 @@
2525
// -------------------------------------------------
2626
// write / read behaviour
2727
// -------------------------------------------------
28-
$case->expect(function (Expect $expect) {
28+
$case->check(function (Expect $expect) {
2929

3030
$s = new Stream(Stream::TEMP, 'w+');
3131
$bytes = $s->write('Hello');
3232

33-
$expect->expect($bytes)
33+
$expect->against($bytes)
3434
->isInt()
3535
->isGreaterThan( 1);
3636
});
3737

3838

39-
$case->expect(function (Expect $expect) {
39+
$case->check(function (Expect $expect) {
4040

4141
$s = new Stream(Stream::TEMP, 'w+');
4242
$s->write('HelloWorld');
@@ -45,22 +45,22 @@
4545
$first = $s->read(5);
4646
$rest = $s->getContents();
4747

48-
$expect->expect($first)->isEqualTo('Hello');
49-
$expect->expect($rest)->isEqualTo('World');
48+
$expect->against($first)->isEqualTo('Hello');
49+
$expect->against($rest)->isEqualTo('World');
5050
});
5151

5252

5353
// -------------------------------------------------
5454
// __toString rewind behaviour
5555
// -------------------------------------------------
5656

57-
$case->expect(function (Expect $expect) {
57+
$case->check(function (Expect $expect) {
5858

5959
$s = new Stream(Stream::TEMP, 'w+');
6060
$s->write('ABC');
6161
$s->read(1);
6262

63-
$expect->expect((string)$s)
63+
$expect->against((string)$s)
6464
->isString()
6565
->isEqualTo('ABC');
6666
});
@@ -70,14 +70,14 @@
7070
// seek / tell
7171
// -------------------------------------------------
7272

73-
$case->expect(function (Expect $expect) {
73+
$case->check(function (Expect $expect) {
7474

7575
$s = new Stream(Stream::TEMP, 'w+');
7676
$s->write('ABCDE');
7777
$s->rewind();
7878
$s->read(2);
7979

80-
$expect->expect($s->tell())
80+
$expect->against($s->tell())
8181
->isInt()
8282
->isEqualTo(2);
8383
});
@@ -87,12 +87,12 @@
8787
// getLines
8888
// -------------------------------------------------
8989

90-
$case->expect(function (Expect $expect) {
90+
$case->check(function (Expect $expect) {
9191

9292
$s = new Stream(Stream::TEMP, 'w+');
9393
$s->write("A\nB\nC\nD\n");
9494

95-
$expect->expect($s->getLines(2, 3))
95+
$expect->against($s->getLines(2, 3))
9696
->isString()
9797
->isEqualTo("B\nC\n");
9898
});
@@ -102,13 +102,13 @@
102102
// clean
103103
// -------------------------------------------------
104104

105-
$case->expect(function (Expect $expect) {
105+
$case->check(function (Expect $expect) {
106106

107107
$s = new Stream(Stream::TEMP, 'w+');
108108
$s->write('12345');
109109
$s->clean();
110110

111-
$expect->expect($s->getSize())
111+
$expect->against($s->getSize())
112112
->isInt()
113113
->isEqualTo(0);
114114
});
@@ -118,12 +118,12 @@
118118
// close / detach
119119
// -------------------------------------------------
120120

121-
$case->expect(function (Expect $expect) {
121+
$case->check(function (Expect $expect) {
122122

123123
$s = new Stream(Stream::TEMP, 'w+');
124124
$s->close();
125125

126-
$expect->expect($s->getResource())
126+
$expect->against($s->getResource())
127127
->isNull();
128128
});
129129

0 commit comments

Comments
 (0)