11import createMapActionGroup from '../../src/utils/create-map-action-group'
2+ import { ActionGroup } from '@commercetools/sdk-client-v2'
23
34describe ( 'createMapActionGroup' , ( ) => {
45 describe ( 'without actionGroups' , ( ) => {
@@ -18,7 +19,9 @@ describe('createMapActionGroup', () => {
1819 describe ( 'with found `actionGroup` (type)' , ( ) => {
1920 describe ( 'with `group` being `allow`' , ( ) => {
2021 const fn = jest . fn ( )
21- const actionGroups = [ { type : 'base' , group : 'allow' } ]
22+ const actionGroups : Array < ActionGroup > = [
23+ { type : 'base' , group : 'allow' } ,
24+ ]
2225 let mapActionGroup
2326
2427 beforeEach ( ( ) => {
@@ -33,7 +36,9 @@ describe('createMapActionGroup', () => {
3336
3437 describe ( 'with `group` being `ignore`' , ( ) => {
3538 const fn = jest . fn ( )
36- const actionGroups = [ { type : 'base' , group : 'ignore' } ]
39+ const actionGroups : Array < ActionGroup > = [
40+ { type : 'base' , group : 'ignore' } ,
41+ ]
3742 let mapActionGroup
3843
3944 beforeEach ( ( ) => {
@@ -52,7 +57,9 @@ describe('createMapActionGroup', () => {
5257 let mapActionGroup
5358
5459 beforeEach ( ( ) => {
55- mapActionGroup = createMapActionGroup ( actionGroups )
60+ mapActionGroup = createMapActionGroup (
61+ actionGroups as Array < ActionGroup >
62+ )
5663 } )
5764
5865 test ( 'should throw an error' , ( ) => {
@@ -74,7 +81,7 @@ describe('createMapActionGroup', () => {
7481
7582 describe ( 'with non found `actionGroup` (type)' , ( ) => {
7683 const fn = jest . fn ( )
77- const actionGroups = [ { type : 'base' , group : 'allow' } ]
84+ const actionGroups : Array < ActionGroup > = [ { type : 'base' , group : 'allow' } ]
7885 let mapActionGroup
7986
8087 beforeEach ( ( ) => {
0 commit comments