https://pact.io logo
#general
Title
# general
o

Oscar Calderin

05/13/2022, 4:29 PM
Hi team, was the type timestamp removed from PactDslJsonArray?
u

uglyog

05/14/2022, 8:00 AM
use datetime instead
o

Oscar Calderin

05/17/2022, 9:08 AM
Hi @uglyog, should I use datetime with any other parameter? because it is not working for me
this is what I'm doing
Copy code
.body(PactDslJsonArray.arrayMinLike(1)
    .stringType("transactionHash")
    .stringType("originWallet")
    .stringType("destinationWallet")
    .decimalType("amount", 1.0)
    .datetime("creationDate")
    .stringType("method")
    .stringType("status")
    .decimalType("fee")
).toPact();
my consumer tests are passing but the when I'm running my provider tests I'm receiving this error
1.1) body: $.0.creationDate Expected 1652738400000 to match a datetime of 'yyyy-MM-dd'T'HHmmss': Unable to parse the date: 1652738400000
2 Views