Skip to content

Commit

Permalink
feat: got provider state injected values working with provider test #516
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronald Holshausen committed Nov 17, 2020
1 parent 17397be commit 5fdf7eb
Show file tree
Hide file tree
Showing 12 changed files with 221 additions and 116 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ module.exports = {
return axios.get(accountServiceUrl + "/accounts/search/findOneByAccountNumberId", {
params: {
accountNumber: accountId
},
headers: {
Accept: 'application/hal+json'
}
}).then(({ data }) => {
// This is the point where a real transaction service would create the transaction, but for the purpose
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ describe("Transaction service - create a new transaction for an account", () =>
method: "GET",
path: "/accounts/search/findOneByAccountNumberId",
query: { accountNumber: fromProviderState("\${accountNumber}", "100") },
headers: { Accept: "application/json" },
headers: { Accept: "application/hal+json" },
})
.willRespondWith({
status: 200,
Expand All @@ -41,8 +41,8 @@ describe("Transaction service - create a new transaction for an account", () =>
version: integer(0),
name: string("Test"),
accountRef: string("Test001"),
createdDate: datetime("yyyy-MM-dd HH:mm:ss"),
lastModifiedDate: datetime("yyyy-MM-dd HH:mm:ss"),
createdDate: datetime("yyyy-MM-dd'T'HH:mm:ss.SSSX"),
lastModifiedDate: datetime("yyyy-MM-dd'T'HH:mm:ss.SSSX"),
accountNumber: {
id: fromProviderState("\${accountNumber}", 100)
},
Expand Down
Loading

0 comments on commit 5fdf7eb

Please sign in to comment.