Skip to content

Commit

Permalink
Add basic test for CubeListPage.
Browse files Browse the repository at this point in the history
  • Loading branch information
phulin committed Jan 19, 2020
1 parent 60a7794 commit 5788bb1
Show file tree
Hide file tree
Showing 5 changed files with 3,917 additions and 0 deletions.
14 changes: 14 additions & 0 deletions __tests__/src/components/CubeListPage.test.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import React from 'react'
import { render, fireEvent, waitForElement } from '@testing-library/react'
import '@testing-library/jest-dom/extend-expect'

import exampleCardsFull from '../../../fixtures/examplecardsdetails';
import CubeListPage from 'components/CubeListPage';

describe('CubeListPage', () => {
test('displays cards', () => {
const { getByText } = render(<CubeListPage cards={exampleCardsFull} cubeID="1" canEdit={true} maybe={exampleCardsFull} defaultTagColors={[]} defaultShowTagColors={true} defaultSorts={['Color Category', 'Types-Multicolor']} />);

expect(getByText('Ayara, First of Locthwain'));
});
});
Loading

0 comments on commit 5788bb1

Please sign in to comment.