diff --git a/client/src/utils/renderSlideIcon.test.tsx b/client/src/utils/renderSlideIcon.test.tsx index 13aad34237dd672df6feb53f468687e67fa54b34..ed82c2efcd8b880538a98176acead1b7221104b5 100644 --- a/client/src/utils/renderSlideIcon.test.tsx +++ b/client/src/utils/renderSlideIcon.test.tsx @@ -1,7 +1,8 @@ import BuildOutlinedIcon from '@material-ui/icons/BuildOutlined' +import CheckBoxOutlinedIcon from '@material-ui/icons/CheckBoxOutlined' import CreateOutlinedIcon from '@material-ui/icons/CreateOutlined' -import DnsOutlinedIcon from '@material-ui/icons/DnsOutlined' import InfoOutlinedIcon from '@material-ui/icons/InfoOutlined' +import RadioButtonCheckedIcon from '@material-ui/icons/RadioButtonChecked' import { shallow } from 'enzyme' import { RichSlide } from '../interfaces/ApiRichModels' import { renderSlideIcon } from './renderSlideIcon' @@ -34,7 +35,18 @@ it('returns DnsOutlinedIcon correctly ', async () => { expect(icon).toBeDefined() if (icon) { const actualResult = shallow(icon) - const expectedResult = shallow(<DnsOutlinedIcon />) + const expectedResult = shallow(<CheckBoxOutlinedIcon />) + expect(actualResult).toEqual(expectedResult) + } +}) + +it('returns DnsOutlinedIcon correctly ', async () => { + const testSlide = { questions: [{ id: 5, type_id: 4 }] } as RichSlide + const icon = renderSlideIcon(testSlide) + expect(icon).toBeDefined() + if (icon) { + const actualResult = shallow(icon) + const expectedResult = shallow(<RadioButtonCheckedIcon />) expect(actualResult).toEqual(expectedResult) } })