dhis2 / app-platform

DHIS 2 application platform layer with inverted app control
https://platform.dhis2.nu
BSD 3-Clause "New" or "Revised" License
27 stars 16 forks source link

feat: migrate snapshot files too [LIBS-681] #878

Closed KaiVandivier closed 1 month ago

KaiVandivier commented 1 month ago

LIBS-681

Tested out in the Dashboard app, and the snapshots are indeed use for comparison -- the platform changes seem to have removed white space in some snaps as seen in the second screenshot below, for example.

One potential shortcoming of the script I noticed, however, is that it doesn't update file paths for things like mocked jest modules, resulting in errors like:

 FAIL  src/components/Item/VisualizationItem/__tests__/Item.spec.jsx
  ● Test suite failed to run

    Cannot find module '../../ItemHeader/DeleteItemButton.js' from 'src/components/Item/VisualizationItem/__tests__/Item.spec.jsx'

Screenshots

snap-migration snap-test
dhis2-bot commented 1 month ago

:tada: This PR is included in version 12.0.0-alpha.16 :tada:

The release is available on:

Your semantic-release bot :package::rocket: