Skip to content
This repository was archived by the owner on May 22, 2024. It is now read-only.

Commit 4dbf5d5

Browse files
committed
fixed jest tests
1 parent a0eac08 commit 4dbf5d5

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

packages/terra-functional-testing/tests/jest/config/utils/getConfigurationOptions.test.js

+14-5
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,9 @@ describe('getCapabilities', () => {
3434

3535
const defaultWebpackPath = path.resolve(process.cwd(), 'webpack.config.js');
3636
const capabilities = getCapabilities(options.browsers, !!options.gridUrl);
37-
37+
const url = `http://${options.externalHost}:${options.externalPort}`;
3838
const expectedConfig = {
39-
baseUrl: `http://${options.externalHost}:${options.externalPort}`,
39+
baseUrl: url,
4040
capabilities,
4141
hostname: options.gridUrl,
4242
port: 80,
@@ -47,6 +47,7 @@ describe('getCapabilities', () => {
4747
buildType: BUILD_TYPE.branchEventCause,
4848
buildUrl: 'www.buildurl.com',
4949
disableSeleniumService: true,
50+
disableServer: undefined,
5051
formFactor: options.formFactor,
5152
gitApiUrl: 'www.gitapiurl.com',
5253
gitToken: '12345',
@@ -59,6 +60,8 @@ describe('getCapabilities', () => {
5960
site: options.site,
6061
theme: options.theme,
6162
overrideTheme: options.theme,
63+
url,
64+
useHttps: undefined,
6265
updateScreenshots: true,
6366
useRemoteReferenceScreenshots: true,
6467
webpackConfig: defaultWebpackPath,
@@ -111,6 +114,7 @@ describe('getCapabilities', () => {
111114
buildType: BUILD_TYPE.branchEventCause,
112115
buildUrl: 'www.buildurl.com',
113116
disableSeleniumService: true,
117+
disableServer: undefined,
114118
formFactor: options.formFactor,
115119
gitApiUrl: 'www.gitapiurl.com',
116120
gitToken: '12345',
@@ -124,6 +128,8 @@ describe('getCapabilities', () => {
124128
theme: options.theme,
125129
overrideTheme: options.theme,
126130
updateScreenshots: true,
131+
url: 'http://externalHost:3000',
132+
useHttps: undefined,
127133
useRemoteReferenceScreenshots: false,
128134
webpackConfig: defaultWebpackPath,
129135
},
@@ -137,9 +143,9 @@ describe('getCapabilities', () => {
137143
it('should get configuration with empty options', async () => {
138144
const defaultWebpackPath = path.resolve(process.cwd(), 'webpack.config.js');
139145
const capabilities = getCapabilities(undefined, !!undefined);
140-
146+
const url = `http://${getIpAddress()}:8080`;
141147
const expectedConfig = {
142-
baseUrl: `http://${getIpAddress()}:8080`,
148+
baseUrl: url,
143149
capabilities,
144150
hostname: 'localhost',
145151
port: 4444,
@@ -148,6 +154,7 @@ describe('getCapabilities', () => {
148154
buildType: undefined,
149155
buildUrl: undefined,
150156
disableSeleniumService: false,
157+
disableServer: undefined,
151158
formFactor: undefined,
152159
gitApiUrl: undefined,
153160
gitToken: undefined,
@@ -156,11 +163,13 @@ describe('getCapabilities', () => {
156163
issueNumber: undefined,
157164
keepAliveSeleniumDockerService: undefined,
158165
locale: undefined,
166+
overrideTheme: undefined,
159167
port: undefined,
160168
site: undefined,
161169
theme: 'terra-default-theme',
162-
overrideTheme: undefined,
163170
updateScreenshots: undefined,
171+
url,
172+
useHttps: undefined,
164173
useRemoteReferenceScreenshots: undefined,
165174
webpackConfig: defaultWebpackPath,
166175
},

0 commit comments

Comments
 (0)