Skip to content
This repository has been archived by the owner on Apr 20, 2018. It is now read-only.

Compatible with latest RxJS? #8

Open
dannybloe opened this issue Sep 29, 2015 · 3 comments
Open

Compatible with latest RxJS? #8

dannybloe opened this issue Sep 29, 2015 · 3 comments

Comments

@dannybloe
Copy link

Hi there,

I'm going through the tutorials and got stuck at 04_about_time. I think that the tests are too old for the current RxJS version since there doesn't seem to be a Scheduler.timeout.scheduleWithRelative anymore.

@AloofBuddha
Copy link

Seconding this, I'm having the same issue. Rx.Scheduler.timeout appears to be undefined in my version of RxJS (4.0.1). I worked around the problem by replacing Rx.Scheduler.timeout with Rx.Scheduler.default and replacing scheduleWithRelative with scheduleFuture and an additional dummy state value. The final (passing) test follows:

asyncTest('launching an event via a scheduler', function () {
  var received = '';
  var delay = 400; // Fix this value
  Scheduler.default.scheduleFuture('global', delay, function () {
    received = 'Finished';
  });

  setTimeout(function () {
    start();
    equal('Finished', received);
  }, 500);
});

I would push this change myself, except I am currently an Rx neophyte and am a bit hesitant to 'fix' something I'm only starting to grok. Perhaps the simplest temporary solution is to fix the version of RxJS within package.json?

@douglasduteil
Copy link

Can be closed ?

@AloofBuddha
Copy link

The fix looks good to me.

Efp95 pushed a commit to Efp95/RxJSKoans that referenced this issue Aug 8, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants