1
0
mirror of https://github.com/danog/amp.git synced 2024-11-30 04:29:08 +01:00

Remove unnecessary usages of Amp\wrap

This commit is contained in:
Niklas Keller 2017-04-23 13:52:23 +02:00
parent 4f8b656513
commit 4577f92625
2 changed files with 4 additions and 4 deletions

View File

@ -23,7 +23,7 @@ class ProducerTest extends TestCase {
public function testEmit() {
$invoked = false;
Loop::run(Amp\wrap(function () use (&$invoked) {
Loop::run(function () use (&$invoked) {
$value = 1;
$producer = new Producer(function (callable $emit) use ($value) {
@ -42,7 +42,7 @@ class ProducerTest extends TestCase {
$producer->onResolve(function ($exception, $result) use ($value) {
$this->assertSame($result, $value);
});
}));
});
$this->assertTrue($invoked);
}

View File

@ -179,10 +179,10 @@ class StreamIteratorTest extends TestCase {
* @expectedExceptionMessage The stream has not resolved
*/
public function testGetResultBeforeResolution() {
Loop::run(Amp\wrap(function () {
Loop::run(function () {
$streamIterator = new StreamIterator((new Emitter)->stream());
$streamIterator->getResult();
}));
});
}
/**