Fix error in test that says not implemented 'window.open'

This commit is contained in:
Wolfgang Huß 2022-11-09 13:31:59 +01:00
parent 3e4e353878
commit 7402cb5774
9 changed files with 18 additions and 2 deletions

View File

@ -16,7 +16,7 @@ import {
} from '../../db/graphql/posts'
import { createCommentMutation } from '../../db/graphql/comments'
// eslint-disable-next-line no-unused-vars
import { DESCRIPTION_WITHOUT_HTML_LENGTH_MIN } from '../../constants/groups'
import { GROUPDESCRIPTION_WITHOUT_HTML_LENGTH_MIN } from '../../constants/groups'
import CONFIG from '../../config'
import { signupVerificationMutation } from '../../db/graphql/authentications'
@ -25,7 +25,7 @@ CONFIG.CATEGORIES_ACTIVE = false
jest.mock('../../constants/groups', () => {
return {
__esModule: true,
DESCRIPTION_WITHOUT_HTML_LENGTH_MIN: 5,
GROUPDESCRIPTION_WITHOUT_HTML_LENGTH_MIN: 5,
}
})

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('code-of-conduct.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('data-privacy.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('donate.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('faq.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('imprint.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('organization.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('support.vue', () => {
let wrapper

View File

@ -9,6 +9,8 @@ localVue.use(VueMeta, { keyName: 'head' })
const assignMock = jest.fn()
delete window.location
window.location = { assign: assignMock }
delete window.open
window.open = jest.fn()
describe('terms-and-conditions.vue', () => {
let wrapper