-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
76 changed files
with
2,692 additions
and
1,331 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
// | ||
// Copyright (c) 2023-2024 karamem0 | ||
// | ||
// This software is released under the MIT License. | ||
// | ||
// https://github.com/karamem0/hitofude/blob/main/LICENSE | ||
// | ||
|
||
import React from 'react'; | ||
|
||
import '@testing-library/jest-dom'; | ||
import { render, screen } from '@testing-library/react'; | ||
import IntlProvider from '../../providers/IntlProvider'; | ||
import Presenter from './ModalDialog.presenter'; | ||
import ThemeProvider from '../../providers/ThemeProvider'; | ||
|
||
it('should create a shapshot when the open parameter is true', () => { | ||
const params = { | ||
children: ( | ||
<div data-testid="test-Children" /> | ||
), | ||
open: true | ||
}; | ||
const { asFragment } = render( | ||
<IntlProvider> | ||
<ThemeProvider> | ||
<Presenter {...params} /> | ||
</ThemeProvider> | ||
</IntlProvider> | ||
); | ||
expect(asFragment()).toMatchSnapshot(); | ||
expect(screen.getByTestId('test-Children')).toBeInTheDocument(); | ||
}); | ||
|
||
it('should create a shapshot when the open parameter is false', () => { | ||
const params = { | ||
children: ( | ||
<div data-testid="test-Children" /> | ||
), | ||
open: false | ||
}; | ||
const { asFragment } = render( | ||
<IntlProvider> | ||
<ThemeProvider> | ||
<Presenter {...params} /> | ||
</ThemeProvider> | ||
</IntlProvider> | ||
); | ||
expect(asFragment()).toMatchSnapshot(); | ||
expect(screen.queryByTestId('test-Children')).not.toBeInTheDocument(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
// | ||
// Copyright (c) 2023-2024 karamem0 | ||
// | ||
// This software is released under the MIT License. | ||
// | ||
// https://github.com/karamem0/hitofude/blob/main/LICENSE | ||
// | ||
|
||
import React from 'react'; | ||
|
||
import '@testing-library/jest-dom'; | ||
import { render, screen } from '@testing-library/react'; | ||
import IntlProvider from '../../providers/IntlProvider'; | ||
import Presenter from './MsalAdapter.presenter'; | ||
import ThemeProvider from '../../providers/ThemeProvider'; | ||
|
||
it('should create a shapshot when the loading parameter is true', () => { | ||
const params = { | ||
children: ( | ||
<div data-testid="test-Children" /> | ||
), | ||
loading: true | ||
}; | ||
const { asFragment } = render( | ||
<IntlProvider> | ||
<ThemeProvider> | ||
<Presenter {...params} /> | ||
</ThemeProvider> | ||
</IntlProvider> | ||
); | ||
expect(asFragment()).toMatchSnapshot(); | ||
expect(screen.queryByTestId('test-Children')).not.toBeInTheDocument(); | ||
}); | ||
|
||
it('should create a shapshot when the loading parameter is false', () => { | ||
const params = { | ||
children: ( | ||
<div data-testid="test-Children" /> | ||
), | ||
loading: false | ||
}; | ||
const { asFragment } = render( | ||
<IntlProvider> | ||
<ThemeProvider> | ||
<Presenter {...params} /> | ||
</ThemeProvider> | ||
</IntlProvider> | ||
); | ||
expect(asFragment()).toMatchSnapshot(); | ||
expect(screen.getByTestId('test-Children')).toBeInTheDocument(); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.