Skip to content

Commit 903dd3f

Browse files
authored
fix: Deprecated functional tests rest transport options (#255)
1 parent 4225897 commit 903dd3f

File tree

9 files changed

+54
-43
lines changed

9 files changed

+54
-43
lines changed

test/functional/deprecated/commandsFunctional.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,16 @@ const { config, printConfig } = require('../config');
3333
if (config.transport !== 'idb' && config.transport !== 'rest') {
3434
throw new Error('Only idb and rest transports are available for deprecated tests');
3535
}
36-
const { database, username, password } = config.transportOptions;
36+
const {
37+
database, username, password, host, port = 80, path,
38+
} = config.transportOptions;
3739

3840
let restOptions = null;
3941
if (config.transport === 'rest') {
4042
restOptions = {
41-
hodt: config.host,
42-
port: config.port || 80,
43-
path: config.path,
43+
host,
44+
port,
45+
path,
4446
};
4547
}
4648

test/functional/deprecated/iDataQueueFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
3030
throw new Error('Only idb and rest transports are available for deprecated tests');
3131
}
3232

33-
const { database, username, password } = config.transportOptions;
33+
const {
34+
database, username, password, host, port = 80, path,
35+
} = config.transportOptions;
3436

3537
let restOptions = null;
36-
3738
if (config.transport === 'rest') {
3839
restOptions = {
39-
hodt: config.host,
40-
port: config.port || 80,
41-
path: config.path,
40+
host,
41+
port,
42+
path,
4243
};
4344
}
4445

test/functional/deprecated/iNetworkFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
2929
throw new Error('Only idb and rest transports are available for deprecated tests');
3030
}
3131

32-
const { database, username, password } = config.transportOptions;
32+
const {
33+
database, username, password, host, port = 80, path,
34+
} = config.transportOptions;
3335

3436
let restOptions = null;
35-
3637
if (config.transport === 'rest') {
3738
restOptions = {
38-
hodt: config.host,
39-
port: config.port || 80,
40-
path: config.path,
39+
host,
40+
port,
41+
path,
4142
};
4243
}
4344

test/functional/deprecated/iObjFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
2929
throw new Error('Only idb and rest transports are available for deprecated tests');
3030
}
3131

32-
const { database, username, password } = config.transportOptions;
32+
const {
33+
database, username, password, host, port = 80, path,
34+
} = config.transportOptions;
3335

3436
let restOptions = null;
35-
3637
if (config.transport === 'rest') {
3738
restOptions = {
38-
hodt: config.host,
39-
port: config.port || 80,
40-
path: config.path,
39+
host,
40+
port,
41+
path,
4142
};
4243
}
4344

test/functional/deprecated/iPgmFunctional.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
3030
throw new Error('Only idb and rest transports are available for deprecated tests');
3131
}
3232

33-
const { database, username, password } = config.transportOptions;
33+
const {
34+
database, username, password, host, port = 80, path,
35+
} = config.transportOptions;
3436

3537
let restOptions = null;
3638
if (config.transport === 'rest') {
3739
restOptions = {
38-
hodt: config.host,
39-
port: config.port || 80,
40-
path: config.path,
40+
host,
41+
port,
42+
path,
4143
};
4244
}
4345

test/functional/deprecated/iProdFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
2929
throw new Error('Only idb and rest transports are available for deprecated tests');
3030
}
3131

32-
const { database, username, password } = config.transportOptions;
32+
const {
33+
database, username, password, host, port = 80, path,
34+
} = config.transportOptions;
3335

3436
let restOptions = null;
35-
3637
if (config.transport === 'rest') {
3738
restOptions = {
38-
hodt: config.host,
39-
port: config.port || 80,
40-
path: config.path,
39+
host,
40+
port,
41+
path,
4142
};
4243
}
4344

test/functional/deprecated/iSqlFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,15 +31,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
3131
throw new Error('Only idb and rest transports are available for deprecated tests');
3232
}
3333

34-
const { database, username, password } = config.transportOptions;
34+
const {
35+
database, username, password, host, port = 80, path,
36+
} = config.transportOptions;
3537

3638
let restOptions = null;
37-
3839
if (config.transport === 'rest') {
3940
restOptions = {
40-
hodt: config.host,
41-
port: config.port || 80,
42-
path: config.path,
41+
host,
42+
port,
43+
path,
4344
};
4445
}
4546

test/functional/deprecated/iUserSpaceFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,15 +29,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
2929
throw new Error('Only idb and rest transports are available for deprecated tests');
3030
}
3131

32-
const { database, username, password } = config.transportOptions;
32+
const {
33+
database, username, password, host, port = 80, path,
34+
} = config.transportOptions;
3335

3436
let restOptions = null;
35-
3637
if (config.transport === 'rest') {
3738
restOptions = {
38-
hodt: config.host,
39-
port: config.port || 80,
40-
path: config.path,
39+
host,
40+
port,
41+
path,
4142
};
4243
}
4344

test/functional/deprecated/iWorkFunctional.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,15 +30,16 @@ if (config.transport !== 'idb' && config.transport !== 'rest') {
3030
throw new Error('Only idb and rest transports are available for deprecated tests');
3131
}
3232

33-
const { database, username, password } = config.transportOptions;
33+
const {
34+
database, username, password, host, port = 80, path,
35+
} = config.transportOptions;
3436

3537
let restOptions = null;
36-
3738
if (config.transport === 'rest') {
3839
restOptions = {
39-
hodt: config.host,
40-
port: config.port || 80,
41-
path: config.path,
40+
host,
41+
port,
42+
path,
4243
};
4344
}
4445

0 commit comments

Comments
 (0)