Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
eps1lon committed Feb 9, 2019
1 parent 459b8f8 commit 32699b1
Showing 1 changed file with 13 additions and 14 deletions.
27 changes: 13 additions & 14 deletions packages/material-ui/src/Slide/Slide.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import Slide, { setTranslateValue } from './Slide';
import transitions, { easing } from '../styles/transitions';
import createMuiTheme from '../styles/createMuiTheme';

describe('<Slide />', () => {
describe.only('<Slide />', () => {
let shallow;
let mount;
const SlideNaked = unwrap(Slide);
Expand Down Expand Up @@ -39,19 +39,14 @@ describe('<Slide />', () => {
style={{ color: 'red', backgroundColor: 'yellow' }}
theme={createMuiTheme()}
>
<div style={{ color: 'blue' }} />
<div id="with-slide" style={{ color: 'blue' }} />
</SlideNaked>,
);
assert.deepEqual(
wrapper
.childAt(0)
.childAt(0)
.props().style,
{
backgroundColor: 'yellow',
color: 'blue',
},
);
assert.deepEqual(wrapper.find('#with-slide').props().style, {
backgroundColor: 'yellow',
color: 'blue',
visibility: undefined,
});
});

describe('event callbacks', () => {
Expand Down Expand Up @@ -303,8 +298,12 @@ describe('<Slide />', () => {

describe('server-side', () => {
it('should be initially hidden', () => {
const wrapper = shallow(<Slide {...defaultProps} in={false} />);
assert.strictEqual(wrapper.find(Transition).childAt(0).props().style.visibility, 'hidden');
const wrapper = mount(
<Slide {...defaultProps} in={false}>
<div id="with-slide" />
</Slide>,
);
assert.strictEqual(wrapper.find('#with-slide').props().style.visibility, 'hidden');
});
});
});

0 comments on commit 32699b1

Please sign in to comment.