@@ -109,6 +109,24 @@ test('should work with husky commitmsg hook in sub packages', async () => {
109
109
await execa ( 'git' , [ 'commit' , '-m' , '"test: this should work"' ] , { cwd} ) ;
110
110
} ) ;
111
111
112
+ test ( 'should work with husky via commitlint -e $GIT_PARAMS' , async ( ) => {
113
+ const cwd = await git . bootstrap ( 'fixtures/husky/integration' ) ;
114
+ await writePkg ( { scripts : { commitmsg : `'${ bin } ' -e $GIT_PARAMS` } } , { cwd} ) ;
115
+
116
+ await execa ( 'npm' , [ 'install' ] , { cwd} ) ;
117
+ await execa ( 'git' , [ 'add' , 'package.json' ] , { cwd} ) ;
118
+ await execa ( 'git' , [ 'commit' , '-m' , '"test: this should work"' ] , { cwd} ) ;
119
+ } ) ;
120
+
121
+ test ( 'should work with husky via commitlint -e %GIT_PARAMS%' , async ( ) => {
122
+ const cwd = await git . bootstrap ( 'fixtures/husky/integration' ) ;
123
+ await writePkg ( { scripts : { commitmsg : `'${ bin } ' -e %GIT_PARAMS%` } } , { cwd} ) ;
124
+
125
+ await execa ( 'npm' , [ 'install' ] , { cwd} ) ;
126
+ await execa ( 'git' , [ 'add' , 'package.json' ] , { cwd} ) ;
127
+ await execa ( 'git' , [ 'commit' , '-m' , '"test: this should work"' ] , { cwd} ) ;
128
+ } ) ;
129
+
112
130
test ( 'should work with husky via commitlint -e $HUSKY_GIT_PARAMS' , async ( ) => {
113
131
const cwd = await git . bootstrap ( 'fixtures/husky/integration' ) ;
114
132
await writePkg (
0 commit comments