Skip to content

Commit 014b3cd

Browse files
Add E2E test for stream pause behavior
1 parent e74cde3 commit 014b3cd

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

e2e/playwright/test-network-and-connection-issues.spec.ts

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
import type { EngineCommand } from '@src/lang/std/artifactGraph'
22
import { uuidv4 } from '@src/lib/utils'
33

4-
import { commonPoints, getUtils, TEST_COLORS, circleMove } from '@e2e/playwright/test-utils'
4+
import {
5+
commonPoints,
6+
getUtils,
7+
TEST_COLORS,
8+
circleMove,
9+
} from '@e2e/playwright/test-utils'
510
import { expect, test } from '@e2e/playwright/zoo-test'
611

712
test.describe(
@@ -299,9 +304,12 @@ profile001 = startProfile(sketch001, at = [44.41, 59.65])
299304
const line = await u.getBoundingBox('[data-overlay-index="0"]')
300305
const angle = await u.getAngle('[data-overlay-index="0"]')
301306
const midPoint = {
302-
x: line.x + (Math.sin(angle/360 * Math.PI*2) * line.width) / 2,
307+
x: line.x + (Math.sin((angle / 360) * Math.PI * 2) * line.width) / 2,
303308
// Different coordinate space, need to -1 to fix it up
304-
y: (line.y + (Math.cos(angle/360 * Math.PI*2) * line.height) / 2) * -1,
309+
y:
310+
(line.y +
311+
(Math.cos((angle / 360) * Math.PI * 2) * line.height) / 2) *
312+
-1,
305313
}
306314
await page.getByRole('button', { name: 'Exit Sketch' }).click()
307315

0 commit comments

Comments
 (0)