Skip to content

Commit f853423

Browse files
committed
Fix failing test
1 parent 9b05ec7 commit f853423

File tree

1 file changed

+14
-3
lines changed

1 file changed

+14
-3
lines changed

tests/client/utils/useDefaultFields.tests.js

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -247,13 +247,24 @@ describe('Client-Utils-useDefaultFields', () => {
247247

248248
it('empty array population skip', () => {
249249
const fields = [];
250-
const target = [];
250+
const target1 = [{
251+
property: 'connection',
252+
label: 'Connection Name',
253+
edit: {
254+
required: true,
255+
type: 'text',
256+
component: 'InputText',
257+
options: undefined,
258+
onChange: undefined
259+
}
260+
}];
261+
const target2 = [];
251262

252263
useDefaultFields.useConnectionsField(true, fields, []);
253-
expect(fields).to.deep.equal(target);
264+
expect(fields).to.deep.equal(target1);
254265

255266
useDefaultFields.useConnectionsField(true, fields, connection);
256-
expect(fields).to.deep.equal(target);
267+
expect(fields).to.deep.equal(target2);
257268
});
258269

259270
it('pre populated array', () => {

0 commit comments

Comments
 (0)