Skip to content

Commit

Permalink
[locale] id: Fix short name for august in id locale (#4184)
Browse files Browse the repository at this point in the history
* Update id.js

* Revert "Update id.js"

This reverts commit 587f604.

* change id.js
  • Loading branch information
duxinxiao authored and marwahaha committed Mar 2, 2018
1 parent 49985eb commit 6adc6ee
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/locale/id.js
Expand Up @@ -7,7 +7,7 @@ import moment from '../moment';

export default moment.defineLocale('id', {
months : 'Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember'.split('_'),
monthsShort : 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nov_Des'.split('_'),
monthsShort : 'Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des'.split('_'),
weekdays : 'Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu'.split('_'),
weekdaysShort : 'Min_Sen_Sel_Rab_Kam_Jum_Sab'.split('_'),
weekdaysMin : 'Mg_Sn_Sl_Rb_Km_Jm_Sb'.split('_'),
Expand Down Expand Up @@ -72,4 +72,3 @@ export default moment.defineLocale('id', {
doy : 7 // The week that contains Jan 1st is the first week of the year.
}
});

6 changes: 2 additions & 4 deletions src/test/locale/id.js
Expand Up @@ -3,7 +3,7 @@ import moment from '../../moment';
localeModule('id');

test('parse', function (assert) {
var tests = 'Januari Jan_Februari Feb_Maret Mar_April Apr_Mei Mei_Juni Jun_Juli Jul_Agustus Ags_September Sep_Oktober Okt_November Nov_Desember Des'.split('_'), i;
var tests = 'Januari Jan_Februari Feb_Maret Mar_April Apr_Mei Mei_Juni Jun_Juli Jul_Agustus Agt_September Sep_Oktober Okt_November Nov_Desember Des'.split('_'), i;
function equalTest(input, mmm, i) {
assert.equal(moment(input, mmm).month(), i, input + ' should be month ' + (i + 1));
}
Expand Down Expand Up @@ -54,7 +54,7 @@ test('format', function (assert) {
});

test('format month', function (assert) {
var expected = 'Januari Jan_Februari Feb_Maret Mar_April Apr_Mei Mei_Juni Jun_Juli Jul_Agustus Ags_September Sep_Oktober Okt_November Nov_Desember Des'.split('_'), i;
var expected = 'Januari Jan_Februari Feb_Maret Mar_April Apr_Mei Mei_Juni Jun_Juli Jul_Agustus Agt_September Sep_Oktober Okt_November Nov_Desember Des'.split('_'), i;
for (i = 0; i < expected.length; i++) {
assert.equal(moment([2011, i, 1]).format('MMMM MMM'), expected[i], expected[i]);
}
Expand Down Expand Up @@ -169,5 +169,3 @@ test('weeks year starting sunday formatted', function (assert) {
assert.equal(moment([2012, 0, 8]).format('w ww wo'), '2 02 2', 'Jan 8 2012 should be week 2');
assert.equal(moment([2012, 0, 9]).format('w ww wo'), '3 03 3', 'Jan 9 2012 should be week 3');
});


0 comments on commit 6adc6ee

Please sign in to comment.