Fix UI tests
This commit is contained in:
parent
bf19ffc0a5
commit
e16df483f3
|
@ -9,7 +9,7 @@ import { MemoryRouter } from 'react-router-dom'
|
||||||
|
|
||||||
import * as authentication from './helpers/authentication'
|
import * as authentication from './helpers/authentication'
|
||||||
|
|
||||||
require('./localization').default()
|
require('./localization').setupLocalization()
|
||||||
|
|
||||||
jest.mock('./helpers/authentication.ts')
|
jest.mock('./helpers/authentication.ts')
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ import SharePage, {
|
||||||
import { SIDEBAR_DOWNLOAD_QUERY } from '../../components/sidebar/SidebarDownload'
|
import { SIDEBAR_DOWNLOAD_QUERY } from '../../components/sidebar/SidebarDownload'
|
||||||
import { SHARE_ALBUM_QUERY } from './AlbumSharePage'
|
import { SHARE_ALBUM_QUERY } from './AlbumSharePage'
|
||||||
|
|
||||||
require('../../localization').default()
|
require('../../localization').setupLocalization()
|
||||||
|
|
||||||
describe('load correct share page, based on graphql query', () => {
|
describe('load correct share page, based on graphql query', () => {
|
||||||
const token = 'TOKEN123'
|
const token = 'TOKEN123'
|
||||||
|
|
|
@ -10,7 +10,7 @@ import {
|
||||||
} from '@testing-library/react'
|
} from '@testing-library/react'
|
||||||
import { MemoryRouter } from 'react-router-dom'
|
import { MemoryRouter } from 'react-router-dom'
|
||||||
|
|
||||||
require('../../localization').default()
|
require('../../localization').setupLocalization()
|
||||||
|
|
||||||
describe('routes', () => {
|
describe('routes', () => {
|
||||||
test('unauthorized root path should navigate to login page', async () => {
|
test('unauthorized root path should navigate to login page', async () => {
|
||||||
|
|
|
@ -4,7 +4,7 @@ import React from 'react'
|
||||||
import { render, screen } from '@testing-library/react'
|
import { render, screen } from '@testing-library/react'
|
||||||
import { MetadataInfo } from './MediaSidebar'
|
import { MetadataInfo } from './MediaSidebar'
|
||||||
|
|
||||||
require('../../localization').default()
|
require('../../localization').setupLocalization()
|
||||||
|
|
||||||
describe('MetadataInfo', () => {
|
describe('MetadataInfo', () => {
|
||||||
test('without EXIF information', async () => {
|
test('without EXIF information', async () => {
|
||||||
|
|
Loading…
Reference in New Issue