File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -18,13 +18,13 @@ describe('buildUserAgentString', () => {
1818 // Prefix: 'NodejsDatabricksSqlConnector/'
1919 // Version: three period-separated digits and optional suffix
2020 const re =
21- / ^ (?< productName > N o d e j s D a t a b r i c k s S q l C o n n e c t o r ) \/ (?< productVersion > \d + \. \d + \. \d + ( - [ ^ ( ] + ) ? ) \( (?< comment > [ ^ ) ] + ) \) $ / i;
21+ / ^ (?< productName > N o d e j s D a t a b r i c k s S q l C o n n e c t o r ) \/ (?< productVersion > \d + \. \d + \. \d + ( - [ ^ ( ] + ) ? ) \s * \ ((?< comment > [ ^ ) ] + ) \) $ / i;
2222 const match = re . exec ( ua ) ;
2323 expect ( match ) . to . not . be . eq ( null ) ;
2424
2525 const { comment } = match . groups ;
2626
27- expect ( comment . split ( ';' ) . length ) . to . be . gte ( 2 ) ; // at least Node ans OS version should be there
27+ expect ( comment . split ( ';' ) . length ) . to . be . gte ( 2 ) ; // at least Node and OS version should be there
2828
2929 if ( clientId ) {
3030 expect ( comment . trim ( ) ) . to . satisfy ( ( s ) => s . startsWith ( `${ clientId } ;` ) ) ;
You can’t perform that action at this time.
0 commit comments