Skip to content

Commit

Permalink
Pass serialized string to mutation instead of number
Browse files Browse the repository at this point in the history
Co-authored-by: sjvans <[email protected]>
  • Loading branch information
schwma and sjvans authored Apr 18, 2024
1 parent db15be7 commit 12bfd65
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/tests/types.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -433,7 +433,7 @@ describe('graphql - types parsing and validation', () => {
test('cds.Decimal is correctly parsed from input literal numeric string value', async () => {
const number = 123.45
const value = String(number)
const body = _getMutationForFieldWithLiteralValue(field, number, true)
const body = _getMutationForFieldWithLiteralValue(field, value, true)
const data = { TypesService: { MyEntity: { create: [{ [field]: value }] } } }
const response = await POST('/graphql', body)
expect(response.data).toEqual({ data })
Expand Down

0 comments on commit 12bfd65

Please sign in to comment.