sum.lua 297 B

123456789
  1. describe('sum', function()
  2. it('passes through errors from the source', function()
  3. expect(Rx.Observable.throw():sum().subscribe).to.fail()
  4. end)
  5. it('produces the sum of the numeric values from the source', function()
  6. expect(Rx.Observable.fromRange(3):sum()).to.produce(6)
  7. end)
  8. end)