How to use the delay.reject function in delay

To help you get started, we’ve selected a few delay examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github werwolfby / monitorrent / test / unit / specs / store / modules / trackers.spec.js View on Github external
            sandbox.stub(api.default.trackers, 'tracker', t => delay.reject(0, new Error()))
github werwolfby / monitorrent / test / unit / specs / Topics / TopicsExecute.spec.js View on Github external
expect(vm.$refs.executeAllMenuItem).to.be.ok

        await Vue.nextTick()

        vm.$refs.executeMenu.$el.click()

        await Vue.nextTick()

        const executeRaised = new Promise(resolve => vm.$on('execute', () => resolve()))

        vm.$refs.executeAllMenuItem.$el.click()

        await Vue.nextTick()

        const delay5 = delay.reject(5)

        await Promise.race([executeRaised, delay5])
    })
github werwolfby / monitorrent / test / unit / specs / store / modules / trackers.spec.js View on Github external
            sandbox.stub(api.default.trackers, 'all', () => delay.reject(0, error))

delay

Delay a promise a specified amount of time

MIT
Latest version published 1 year ago

Package Health Score

73 / 100
Full package analysis

Popular delay functions