Skip to content

Commit 08988eb

Browse files
lint
Signed-off-by: Vikrant Puppala <vikrant.puppala@databricks.com>
1 parent 85249ca commit 08988eb

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

lib/connection/connections/HttpConnection.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,9 @@ export default class HttpConnection implements IConnectionProvider {
9898

9999
this.connection = new ThriftHttpConnection(
100100
{
101-
url: `${options.https ? 'https' : 'http'}://${options.host.replace(/\/$/, '')}:${options.port}${options.path ?? '/'}`,
101+
url: `${options.https ? 'https' : 'http'}://${options.host.replace(/\/$/, '')}:${options.port}${
102+
options.path ?? '/'
103+
}`,
102104
transport: thrift.TBufferedTransport,
103105
protocol: thrift.TBinaryProtocol,
104106
getRetryPolicy: () => this.getRetryPolicy(),

tests/unit/connection/connections/HttpConnection.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -140,16 +140,16 @@ describe('HttpConnection.connect', () => {
140140
const testCases: TestCase[] = [
141141
{
142142
input: { host: 'xyz.com/', path: '/sql/v1' },
143-
expected: 'https://xyz.com:443/sql/v1'
143+
expected: 'https://xyz.com:443/sql/v1',
144144
},
145145
{
146146
input: { host: 'xyz.com', path: '/sql/v1' },
147-
expected: 'https://xyz.com:443/sql/v1'
147+
expected: 'https://xyz.com:443/sql/v1',
148148
},
149149
{
150150
input: { host: 'xyz.com/', path: undefined },
151-
expected: 'https://xyz.com:443/'
152-
}
151+
expected: 'https://xyz.com:443/',
152+
},
153153
];
154154

155155
for (const testCase of testCases) {

0 commit comments

Comments
 (0)