Skip to content

Commit f345a07

Browse files
authored
Update helix e2e test to account for 90deg engine change (KittyCAD#6341)
The engine fixed the start angle for helices, but our e2e test has a pixel check so it broke. I made the test change the `startAngle` by `-90` rather than try to hunt around for a new working pixel value.
1 parent f5e3b4b commit f345a07

File tree

1 file changed

+21
-4
lines changed

1 file changed

+21
-4
lines changed

e2e/playwright/point-click.spec.ts

Lines changed: 21 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1046,7 +1046,7 @@ openSketch = startSketchOn(XY)
10461046
}) => {
10471047
// One dumb hardcoded screen pixel value
10481048
const testPoint = { x: 620, y: 257 }
1049-
const expectedOutput = `helix001 = helix( axis = X, radius = 5, length = 5, revolutions = 1, angleStart = 360, ccw = false,)`
1049+
const expectedOutput = `helix001 = helix( axis = X, radius = 5, length = 5, revolutions = 1, angleStart = 270, ccw = false,)`
10501050
const expectedLine = `axis=X,`
10511051

10521052
await homePage.goToModelingScene()
@@ -1072,6 +1072,23 @@ openSketch = startSketchOn(XY)
10721072
await expect.poll(() => page.getByText('Axis').count()).toBe(6)
10731073
await cmdBar.progressCmdBar()
10741074
await cmdBar.progressCmdBar()
1075+
await cmdBar.expectState({
1076+
stage: 'arguments',
1077+
currentArgKey: 'angleStart',
1078+
highlightedHeaderArg: 'angleStart',
1079+
currentArgValue: '360',
1080+
headerArguments: {
1081+
Mode: 'Axis',
1082+
Axis: 'X',
1083+
Revolutions: '1',
1084+
AngleStart: '',
1085+
Length: '',
1086+
Radius: '',
1087+
CounterClockWise: '',
1088+
},
1089+
commandName: 'Helix',
1090+
})
1091+
await cmdBar.currentArgumentInput.locator('.cm-content').fill('270')
10751092
await cmdBar.progressCmdBar()
10761093
await cmdBar.progressCmdBar()
10771094
await cmdBar.progressCmdBar()
@@ -1080,7 +1097,7 @@ openSketch = startSketchOn(XY)
10801097
headerArguments: {
10811098
Mode: 'Axis',
10821099
Axis: 'X',
1083-
AngleStart: '360',
1100+
AngleStart: '270',
10841101
Revolutions: '1',
10851102
Length: '5',
10861103
Radius: '5',
@@ -1115,7 +1132,7 @@ openSketch = startSketchOn(XY)
11151132
currentArgValue: '',
11161133
headerArguments: {
11171134
Axis: 'X',
1118-
AngleStart: '360',
1135+
AngleStart: '270',
11191136
Revolutions: '1',
11201137
Radius: '5',
11211138
Length: initialInput,
@@ -1131,7 +1148,7 @@ openSketch = startSketchOn(XY)
11311148
stage: 'review',
11321149
headerArguments: {
11331150
Axis: 'X',
1134-
AngleStart: '360',
1151+
AngleStart: '270',
11351152
Revolutions: '1',
11361153
Radius: '5',
11371154
Length: newInput,

0 commit comments

Comments
 (0)