chore: remove @types/js-cookie
This commit is contained in:
parent
8a86cfd072
commit
0cd1a877f1
3 changed files with 4 additions and 11 deletions
|
@ -100,7 +100,6 @@
|
|||
"@types/fs-extra": "^11.0.1",
|
||||
"@types/isomorphic-fetch": "^0.0.36",
|
||||
"@types/jest": "^29.5.2",
|
||||
"@types/js-cookie": "^3.0.3",
|
||||
"@types/lodash.merge": "^4.6.7",
|
||||
"@types/node": "20.2.5",
|
||||
"@types/node-cron": "^3.0.2",
|
||||
|
|
7
pnpm-lock.yaml
generated
7
pnpm-lock.yaml
generated
|
@ -210,9 +210,6 @@ devDependencies:
|
|||
'@types/jest':
|
||||
specifier: ^29.5.2
|
||||
version: 29.5.2
|
||||
'@types/js-cookie':
|
||||
specifier: ^3.0.3
|
||||
version: 3.0.3
|
||||
'@types/lodash.merge':
|
||||
specifier: ^4.6.7
|
||||
version: 4.6.7
|
||||
|
@ -2965,10 +2962,6 @@ packages:
|
|||
pretty-format: 29.5.0
|
||||
dev: true
|
||||
|
||||
/@types/js-cookie@3.0.3:
|
||||
resolution: {integrity: sha512-Xe7IImK09HP1sv2M/aI+48a20VX+TdRJucfq4vfRVy6nWN8PYPOEnlMRSgxJAgYQIXJVL8dZ4/ilAM7dWNaOww==}
|
||||
dev: true
|
||||
|
||||
/@types/js-levenshtein@1.1.1:
|
||||
resolution: {integrity: sha512-qC4bCqYGy1y/NP7dDVr7KJarn+PbX1nSpwA7JXdu0HxT3QYjO8MJ+cntENtHFVy2dRAyBV23OZ6MxsW1AM1L8g==}
|
||||
dev: true
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import merge from 'lodash.merge';
|
||||
import Cookies from 'js-cookie';
|
||||
import { deleteCookie, setCookie } from 'cookies-next';
|
||||
import { fromPartial } from '@total-typescript/shoehorn';
|
||||
import { getAuthedPageProps, getMessagesPageProps } from '../page-helpers';
|
||||
import englishMessages from '../../messages/en.json';
|
||||
import frenchMessages from '../../messages/fr-FR.json';
|
||||
|
@ -33,7 +34,7 @@ describe('test: getAuthedPageProps()', () => {
|
|||
|
||||
describe('test: getMessagesPageProps()', () => {
|
||||
beforeEach(() => {
|
||||
Cookies.remove('locale');
|
||||
deleteCookie('tipi-locale');
|
||||
});
|
||||
|
||||
it('should return correct messages if the locale is in the session', async () => {
|
||||
|
@ -51,7 +52,7 @@ describe('test: getMessagesPageProps()', () => {
|
|||
it('should return correct messages if the locale in the cookie', async () => {
|
||||
// arrange
|
||||
const ctx = { req: { session: {}, headers: {} } };
|
||||
Cookies.set('locale', 'fr-FR');
|
||||
setCookie('tipi-locale', 'fr-FR', { req: fromPartial(ctx.req) });
|
||||
|
||||
// act
|
||||
// @ts-expect-error - we're passing in a partial context
|
||||
|
|
Loading…
Add table
Reference in a new issue