Skip to content

Commit 46be40a

Browse files
committed
fix: data in object
1 parent 85a98b3 commit 46be40a

File tree

1 file changed

+12
-8
lines changed

1 file changed

+12
-8
lines changed

src/test/tryCatch.test.ts

Lines changed: 12 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -234,11 +234,13 @@ describe('Promise', () => {
234234

235235
expect(error).toBeNull();
236236
expect(result).toMatchObject({
237-
id: '1',
238-
firstName: 'George',
239-
lastName: 'Bluth',
240-
email: 'george.bluth@test.test',
241-
avatar: 'https://eu.ui-avatars.com/api/?name=George+Bluth',
237+
data: {
238+
id: '1',
239+
firstName: 'George',
240+
lastName: 'Bluth',
241+
email: 'george.bluth@test.test',
242+
avatar: 'https://eu.ui-avatars.com/api/?name=George+Bluth',
243+
},
242244
});
243245
});
244246

@@ -255,9 +257,11 @@ describe('Promise', () => {
255257

256258
expect(error).toBeNull();
257259
expect(result).toMatchObject({
258-
id: '7',
259-
firstName: 'Foo',
260-
lastName: 'Bar',
260+
data: {
261+
id: '7',
262+
firstName: 'Foo',
263+
lastName: 'Bar',
264+
},
261265
});
262266
});
263267

0 commit comments

Comments
 (0)