Skip to content

Commit

Permalink
Correct name of tests
Browse files Browse the repository at this point in the history
  • Loading branch information
anxolin committed Aug 30, 2023
1 parent 8ceb521 commit 665959f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/composable/orderTypes/Twap.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -191,18 +191,18 @@ describe('Serialize', () => {
})
})

describe('Deserializes', () => {
test('deserialize: Deserializes correctly', () => {
describe('Deserialize', () => {
test('Deserializes correctly', () => {
const twap = Twap.fromData(TWAP_PARAMS_TEST)
expect(Twap.deserialize(TWAP_SERIALIZED(twap.salt))).toMatchObject(twap)
})

test('deserialize: Throws if invalid', () => {
test('Throws if invalid', () => {
expect(() => Twap.deserialize('0x')).toThrow('InvalidSerializedConditionalOrder')
})
})

describe('To Sting', () => {
describe('To String', () => {
test('toString: Formats correctly', () => {
expect(Twap.fromData(TWAP_PARAMS_TEST).toString()).toEqual(
'twap: Sell total 0x6810e776880C02933D47DB1b9fc05908e5386b96@1000000000000000000 for a minimum of 0xDAE5F1590db13E3B40423B5b5c5fbf175515910b@1000000000000000000 over 10 parts with a spacing of 3600s beginning at time of mining'
Expand Down

0 comments on commit 665959f

Please sign in to comment.