/** * */ public function testNotifyWithParams() { $observable = new Observable(); $observable->attachObserver('foo', function ($num) { return 'foo' . $num; }); $observable->attachObserver('foo', function ($num) { return 'bar' . $num; }); $this->assertEquals(['foo1', 'bar1'], $observable->notifyFooWithParams()); }