Skip to content

Conversation

@ismailsunni
Copy link
Contributor

@ismailsunni ismailsunni commented Dec 3, 2025

@ismailsunni ismailsunni changed the base branch from develop to feat-PB-1383-pinia-store December 3, 2025 11:33
@github-actions github-actions bot added the bug label Dec 3, 2025
@ismailsunni ismailsunni requested a review from Copilot December 3, 2025 11:33
Copilot finished reviewing on behalf of ismailsunni December 3, 2025 11:36
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a crosshair test by correcting the enum validation logic and adding support for crosshair URL parameters without explicit coordinates.

Key Changes:

  • Fixed enum validation in setCrossHair action to check enum values instead of enum keys
  • Added handling for crosshair URL parameters that specify only the type (without coordinates), using map center as the default position

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
packages/viewer/src/store/modules/position/actions/setCrossHair.ts Fixed the crosshair validation check from crossHair in CrossHairs (which checked for enum keys like 'Point', 'Cross') to Object.values(CrossHairs).includes(crossHair) (which correctly checks for enum values like 'point', 'cross')
packages/viewer/src/store/plugins/storeSync/params/crosshair.param.ts Added else-if branch to handle URL parameters where only the crosshair type is provided without coordinates, ensuring the crosshair is placed at the map center as expected by the test

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@cypress
Copy link

cypress bot commented Dec 3, 2025

web-mapviewer    Run #6134

Run Properties:  status check errored Errored #6134  •  git commit 4716db2b55: PB-2064: Fix failed to parse crosshair.
Project web-mapviewer
Branch Review fix-pb-2064-crosshair-test
Run status status check errored Errored #6134
Run duration 12m 36s
Commit git commit 4716db2b55: PB-2064: Fix failed to parse crosshair.
Committer Ismail Sunni
View all properties for this run ↗︎

Test results
Tests that failed  Failures 54
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 19
Tests that did not run due to a failure in a mocha hook  Skipped 7
Tests that passed  Passing 145
View all changes introduced in this branch ↗︎

Tests for review

Failed  drawing.cy.ts • 1 failed test • e2e/chrome/mobile

View Output

Test Artifacts
An uncaught error was detected outside of a test Test Replay Screenshots
Failed  timeSlider.cy.ts • 3 failed tests • e2e/chrome/mobile

View Output

Test Artifacts
Cypress tests covering the time slider, its functionalities and its URL parameter > checking the time slider behavior, both on startup and during use > checks that the time slider is functional and behave correctly part 1 Test Replay Screenshots
Cypress tests covering the time slider, its functionalities and its URL parameter > checking the time slider behavior, both on startup and during use > checks that the time slider is functional and behave correctly with the timeSlider param at startup Test Replay Screenshots
Cypress tests covering the time slider, its functionalities and its URL parameter > checking the time slider behavior, both on startup and during use > behaves correctly when years are being entered in the input Test Replay Screenshots
Failed  print.cy.ts • 1 failed test • e2e/chrome/mobile

View Output

Test Artifacts
An uncaught error was detected outside of a test Test Replay Screenshots
Failed  legacyParamImport.cy.ts • 1 failed test • e2e/chrome/mobile

View Output

Test Artifacts
An uncaught error was detected outside of a test Test Replay Screenshots
Failed  menuTray.cy.ts • 1 failed test • e2e/chrome/mobile

View Output

Test Artifacts
An uncaught error was detected outside of a test Test Replay Screenshots

The first 5 failed specs are shown, see all 23 specs in Cypress Cloud.

@ismailsunni ismailsunni marked this pull request as ready for review December 4, 2025 07:11
@ismailsunni ismailsunni requested a review from pakb December 4, 2025 07:11
@ismailsunni ismailsunni force-pushed the fix-pb-2064-crosshair-test branch from bd739c4 to 4716db2 Compare December 4, 2025 07:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants