Skip to content

Commit 0ba34f2

Browse files
committed
Fix chrome headless test
1 parent ab18c25 commit 0ba34f2

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

tests/test-browser/chrome-test.js

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,10 @@ const puppeteer = require('puppeteer');
33
const inspect = require('util').inspect;
44
const URL = process.argv[2];
55

6-
function testGitExtension(html) {
7-
// Test git icons are present
8-
assert(html.includes('--jp-icon-git-clone'), 'Could not find git clone icon.');
9-
assert(html.includes('--jp-icon-git-pull'), 'Could not find git pull icon.');
10-
assert(html.includes('--jp-icon-git-push'), 'Could not find git push icon.');
6+
async function testGitExtension(page) {
7+
// Test tabbar entry
8+
const gitTabbar = await page.waitForSelector('.lm-TabBar-tab[data-id="jp-git-sessions"]')
9+
assert.ok(gitTabbar, 'Could not find Git Tab entry');
1110
}
1211

1312
async function main() {
@@ -46,7 +45,7 @@ async function main() {
4645
console.error(`Parsed an error from text content: ${error.message}`, error);
4746
}
4847

49-
testGitExtension(html);
48+
await testGitExtension(page);
5049

5150
await browser.close();
5251

0 commit comments

Comments
 (0)