mirror of
https://github.com/apache/superset.git
synced 2026-04-19 08:04:53 +00:00
Use 3 letters month prefix in default date format (#4693)
This commit is contained in:
committed by
GitHub
parent
ed9a56b4ab
commit
29678680ee
@@ -20,6 +20,19 @@ describe('formatDate', () => {
|
||||
it('is a function', () => {
|
||||
assert.isFunction(formatDate);
|
||||
});
|
||||
|
||||
it('shows only year when 1st day of the year', () => {
|
||||
expect(formatDate(new Date('2020-01-01'))).to.equal('2020');
|
||||
});
|
||||
|
||||
it('shows month and year when 1st of month', () => {
|
||||
expect(formatDate(new Date('2020-03-01'))).to.equal('Mar 2020');
|
||||
});
|
||||
|
||||
it('shows weekday when any day of the month', () => {
|
||||
expect(formatDate(new Date('2020-03-03'))).to.equal('Tue Mar 3');
|
||||
expect(formatDate(new Date('2020-03-15'))).to.equal('Sun Mar 15');
|
||||
});
|
||||
});
|
||||
|
||||
describe('fDuration', () => {
|
||||
|
||||
Reference in New Issue
Block a user