adjust some events in nb_roundtrip

hopefully should address some intermittent failures due to race conditions
Merge pull request #5062 from minrk/js-test-races

adjust some events in nb_roundtrip