Skip to content
Snippets Groups Projects
Commit 9c3d1273 authored by astumpff2's avatar astumpff2
Browse files

Completed checkpoint 10

parent 34a2bab7
Branches master
No related tags found
No related merge requests found
// Jest Snapshot v1, https://goo.gl/fbAQLP
exports[`the app has a grid of 3x3 buttons 1`] = `
<div>
<main>
<div
class="maze"
>
<button
class="correct"
/>
<button
class="panel"
/>
<button
class="panel"
/>
</div>
<div
class="maze"
>
<button
class="panel"
/>
<button
class="correct"
/>
<button
class="panel"
/>
</div>
<div
class="maze"
>
<button
class="panel"
/>
<button
class="panel"
/>
<button
class="correct"
/>
</div>
</main>
<main
class="controlPanel"
>
<button
class="reset"
>
Reset Maze
:
</button>
</main>
</div>
`;
...@@ -14,17 +14,17 @@ import { ...@@ -14,17 +14,17 @@ import {
selectButtonOne, selectButtonOne,
selectButtonTwo, selectButtonTwo,
selectButtonThree, selectButtonThree,
} from './invisibleMazeSlice.js'; setAllButtons,
} from './features/invisibleMaze/invisibleMazeSlice.js';
import { InvisibleMaze } from './invisibleMaze.js'; jest.mock('./features/invisibleMaze/invisibleMazeSlice.js', () => ({
import { App } from './invisibleMaze.js';
jest.mock('./invisibleMazeSlice.js', () => ({
selectStepOne: jest.fn().mockName('selectStepOne'), selectStepOne: jest.fn().mockName('selectStepOne'),
selectStepTwo: jest.fn().mockName('selectStepTwo'), selectStepTwo: jest.fn().mockName('selectStepTwo'),
selectStepThree: jest.fn().mockName('selectStepThree'), selectStepThree: jest.fn().mockName('selectStepThree'),
selectButtonOne: jest.fn().mockName('selectButtonOne'), selectButtonOne: jest.fn().mockName('selectButtonOne'),
selectButtonTwo: jest.fn().mockName('selectButtonTwo'), selectButtonTwo: jest.fn().mockName('selectButtonTwo'),
selectButtonThree: jest.fn().mockName('selectButtonThree'), selectButtonThree: jest.fn().mockName('selectButtonThree'),
setAllButtons: jest.fn().mockName('setAllButtons'),
})); }));
describe('the app', () => { describe('the app', () => {
...@@ -36,7 +36,9 @@ describe('the app', () => { ...@@ -36,7 +36,9 @@ describe('the app', () => {
selectButtonTwo.mockReturnValue(9997); selectButtonTwo.mockReturnValue(9997);
selectButtonThree.mockReturnValue(9999); selectButtonThree.mockReturnValue(9999);
const { container } = render( const { container } = render(
</> <Router initialEntries={['/']}>
<App />
</Router>,
); );
expect(container).toMatchSnapshot(); expect(container).toMatchSnapshot();
}); });
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment