mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-11-30 11:54:33 +03:00
459a2c553e
ref https://linear.app/tryghost/issue/ONC-323 When the store gets into a bad state for new posts that causes saves to fail we can detect that by looking at the `model.isNew` property. Currently our best approach to fix this state is to restart the app. - added a `didTransition()` hook to our `lexical-edit.new` route - detects the bad state, logs the error, and triggers a browser refresh - logs with a `recreatedPostIsGood` property that will let us know if we could instead just try recreating the post and avoiding a full refresh (so far we have no reproduction case so we need to learn what we can) - added `sinon-chai` dependency for better assertions on spies/stubs - added `sentry-testkit` dependency so we can test our Sentry integration calls - we can't use sinon for these calls because of the way Sentry's es6 imports work - extracted our full Sentry config object generation to a util function so it can be re-used in unit tests - updated our integrations list to disable the default `dedupe` integration because it can cause very unexpected/difficult to debug test failures when you're asserting using `sentry-testkit` |
||
---|---|---|
.. | ||
analytics.js | ||
bound-one-way.js | ||
caja-sanitizers.js | ||
copy-text-to-clipboard.js | ||
ctrl-or-cmd.js | ||
currency.js | ||
fetch-koenig-lexical.js | ||
flatten-grouped-options.js | ||
get-scroll-parent.js | ||
ghost-paths.js | ||
isNumber.js | ||
link-component.js | ||
member-event-types.js | ||
merge-stats-by-date.js | ||
password-generator.js | ||
publish-options.js | ||
route.js | ||
sentry.js | ||
shortcuts.js | ||
slug-url.js | ||
stats.js | ||
subscription-data.js | ||
window-proxy.js |