Skip to content

Commit e001684

Browse files
committed
Upgrade test
1 parent af98b8c commit e001684

3 files changed

Lines changed: 39 additions & 16 deletions

File tree

__tests__/bubbleNub.js

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -24,22 +24,6 @@ async function sendMessageAndMatchSnapshot(driver, pageObjects, message) {
2424
describe('bubble nub', () => {
2525
let props;
2626

27-
test('with standard setup', async () => {
28-
const { driver, pageObjects } = await setupWebDriver({
29-
props: {
30-
styleOptions: {
31-
bubbleNubOffset: 0,
32-
bubbleNubSize: 10,
33-
bubbleFromUserNubOffset: 0,
34-
bubbleFromUserNubSize: 10
35-
}
36-
},
37-
zoom: 3
38-
});
39-
40-
await sendMessageAndMatchSnapshot(driver, pageObjects, 'layout carousel');
41-
});
42-
4327
beforeEach(() => {
4428
props = {
4529
styleOptions: {
Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
<!doctype html>
2+
<html lang="en-US">
3+
<head>
4+
<link href="/assets/index.css" rel="stylesheet" type="text/css" />
5+
<script crossorigin="anonymous" src="/test-harness.js"></script>
6+
<script crossorigin="anonymous" src="/test-page-object.js"></script>
7+
<script crossorigin="anonymous" src="/__dist__/webchat-es5.js"></script>
8+
</head>
9+
<body>
10+
<main id="webchat"></main>
11+
<script>
12+
run(async function () {
13+
await host.windowSize(1080, 1920);
14+
15+
document.getElementById('webchat').style.zoom = 3;
16+
17+
WebChat.renderWebChat(
18+
{
19+
directLine: WebChat.createDirectLine({ token: await testHelpers.token.fetchDirectLineToken() }),
20+
store: testHelpers.createStore(),
21+
styleOptions: {
22+
bubbleNubOffset: 0,
23+
bubbleNubSize: 10,
24+
bubbleFromUserNubOffset: 0,
25+
bubbleFromUserNubSize: 10
26+
}
27+
},
28+
document.getElementById('webchat')
29+
);
30+
31+
await pageConditions.uiConnected();
32+
33+
await pageObjects.sendMessageViaSendBox('layout carousel');
34+
35+
await host.snapshot('local');
36+
});
37+
</script>
38+
</body>
39+
</html>

__tests__/__image_snapshots__/chrome-docker/bubble-nub-js-bubble-nub-with-standard-setup-1-snap.png renamed to __tests__/html2/bubble/nub/carousel.html.snap-1.png

File renamed without changes.

0 commit comments

Comments
 (0)