@@ -72,7 +72,7 @@ describe('validateFormat', () => {
7272 [ '5.20.0-beta3' ] ,
7373 [ '10.0.0-beta10' ] ,
7474 ] ) ( 'accepts valid version %s' , ( version ) => {
75- expect ( ( ) => validateFormat ( version ) ) . not . toThrow ( ) ;
75+ expect ( ( ) => { validateFormat ( version ) ; } ) . not . toThrow ( ) ;
7676 } ) ;
7777
7878 it . each ( [
@@ -84,7 +84,7 @@ describe('validateFormat', () => {
8484 [ 'not-a-version' ] ,
8585 [ '' ] ,
8686 ] ) ( 'rejects invalid version %s' , ( version ) => {
87- expect ( ( ) => validateFormat ( version ) ) . toThrow ( 'not in the correct format' ) ;
87+ expect ( ( ) => { validateFormat ( version ) ; } ) . toThrow ( 'not in the correct format' ) ;
8888 } ) ;
8989} ) ;
9090
@@ -97,21 +97,21 @@ describe('checkTagDoesNotExist', () => {
9797
9898 it ( 'does not throw when ls-remote returns empty (tag absent)' , ( ) => {
9999 mockExecSync . mockReturnValue ( '' as never ) ;
100- expect ( ( ) => checkTagDoesNotExist ( '3.11.0' ) ) . not . toThrow ( ) ;
100+ expect ( ( ) => { checkTagDoesNotExist ( '3.11.0' ) ; } ) . not . toThrow ( ) ;
101101 } ) ;
102102
103103 it ( 'throws when ls-remote returns a line (tag exists)' , ( ) => {
104104 mockExecSync . mockReturnValue (
105105 'abc123\trefs/tags/3.11.0\n' as never ,
106106 ) ;
107- expect ( ( ) => checkTagDoesNotExist ( '3.11.0' ) ) . toThrow ( 'already exists' ) ;
107+ expect ( ( ) => { checkTagDoesNotExist ( '3.11.0' ) ; } ) . toThrow ( 'already exists' ) ;
108108 } ) ;
109109
110110 it ( 'throws when execSync itself fails' , ( ) => {
111111 mockExecSync . mockImplementation ( ( ) => {
112112 throw new Error ( 'git: not found' ) ;
113113 } ) ;
114- expect ( ( ) => checkTagDoesNotExist ( '3.11.0' ) ) . toThrow ( 'Failed to check remote tags' ) ;
114+ expect ( ( ) => { checkTagDoesNotExist ( '3.11.0' ) ; } ) . toThrow ( 'Failed to check remote tags' ) ;
115115 } ) ;
116116
117117 it ( 'queries the exact ref for the given version' , ( ) => {
0 commit comments