Skip to content
This repository has been archived by the owner on Oct 18, 2023. It is now read-only.

Commit

Permalink
feat(ci): wait a little on CI before attempting to add listeners
Browse files Browse the repository at this point in the history
  • Loading branch information
sublimator committed Jan 25, 2020
1 parent d9eac05 commit 6bedd21
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 3 deletions.
4 changes: 2 additions & 2 deletions packages/coil-extension/test/puppeteer/basic-test.ts
@@ -1,8 +1,8 @@
import {
debug,
env,
initBrowserAndLoginFromEnv,
testMonetization,
env
testMonetization
} from '@coil/puppeteer-utils'

import { testUrls } from './testUrls'
Expand Down
2 changes: 1 addition & 1 deletion packages/coil-extension/test/puppeteer/testUrls.ts
Expand Up @@ -4,8 +4,8 @@ type Domain = string

const urls = {
'https://coil.com': {
youtubeUrl: 'https://www.youtube.com/watch?v=-QMbZx_w2_Y',
twitchUrl: 'https://twitch.tv/vinesauce',
youtubeUrl: 'https://www.youtube.com/watch?v=-QMbZx_w2_Y',
externalSite: 'https://www.xrptipbot.com/',
coilArticle:
'https://coil.com/p/thomasgardnerjr/Margaritaville-Jimmy-Buffett-cover-w-Sharper-s-Florist/dwntYG8d5'
Expand Down
6 changes: 6 additions & 0 deletions packages/coil-puppeteer-utils/src/lib/testMonetization.ts
Expand Up @@ -9,6 +9,8 @@ import {
} from '@web-monetization/types'
import { Browser, Page } from 'puppeteer'

import { env, timeout } from '../index'

import { debug } from './debug'
import {
hasCommonRequestIdAndPaymentPointer,
Expand Down Expand Up @@ -134,6 +136,10 @@ export async function testMonetization({
}, type)
}

if (env.IS_CI) {
await timeout(1e3)
}

await listenFor('monetizationpending')
await listenFor('monetizationstart')
await listenFor('monetizationprogress')
Expand Down

0 comments on commit 6bedd21

Please sign in to comment.