1 | const { format } = require('../src');
|
2 |
|
3 | test('It orders scripts in alphabetical order, keeping pre and post scripts beside their counterparts', () => {
|
4 | const json = {
|
5 | scripts: {
|
6 | test: 'test',
|
7 | pretest: 'pretest',
|
8 | version: 'version',
|
9 | postversion: 'postversion',
|
10 | build: 'build'
|
11 | }
|
12 | };
|
13 |
|
14 | expect(format(json)).toMatchSnapshot();
|
15 | });
|