mirror of
https://github.com/apache/superset.git
synced 2026-04-17 23:25:05 +00:00
Fix click on now in DateFilterControl (#4265)
When clicking on `now` or the infinity sign, the popover closes but the value doesn't show in the label as expected.
This commit is contained in:
committed by
GitHub
parent
b90c410c01
commit
9cf16a4ff2
@@ -42,6 +42,14 @@ describe('DateFilterControl', () => {
|
||||
expect(wrapper.state().num).to.equal('90');
|
||||
}, 10);
|
||||
});
|
||||
it('sets now and closes', () => {
|
||||
const label = wrapper.find('.now').first();
|
||||
label.simulate('click');
|
||||
setTimeout(() => {
|
||||
expect(wrapper.state().free).to.equal('now');
|
||||
expect(wrapper.find('.popover')).to.have.length(0);
|
||||
}, 10);
|
||||
});
|
||||
it('renders 2 dimmed sections', () => {
|
||||
const label = wrapper.find('.label').first();
|
||||
label.simulate('click');
|
||||
|
||||
Reference in New Issue
Block a user