Skip to content

Commit

Permalink
test: jestify transfer-commence test
Browse files Browse the repository at this point in the history
Migrated test from Tap to Jest.

File Path:
packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/transfer-commence.test.ts

This is a PARTIAL resolution to #238

Signed-off-by: awadhana <[email protected]>
  • Loading branch information
awadhana authored and petermetz committed Dec 8, 2021
1 parent 1714c71 commit 713df91
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
1 change: 0 additions & 1 deletion .taprc
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ files:
- ./packages/cactus-plugin-keychain-aws-sm/src/test/typescript/integration/openapi/openapi-validation.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/transfer-initiation.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/transfer-complete.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/transfer-commence.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/odap-api-call.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/odap-api-call-with-ledger-connector.test.ts
- ./packages/cactus-plugin-odap-hermes/src/test/typescript/integration/odap/lock-evidence.test.ts
Expand Down
1 change: 0 additions & 1 deletion jest.config.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import test, { Test } from "tape";
import "jest-extended";
import { randomBytes } from "crypto";
import secp256k1 from "secp256k1";
import { OdapGateway } from "../../../../main/typescript/gateway/odap-gateway";
Expand All @@ -9,7 +9,7 @@ import {
import { v4 as uuidV4 } from "uuid";
import { SHA256 } from "crypto-js";

test("dummy test for transfer commence flow", async (t: Test) => {
test("dummy test for transfer commence flow", async () => {
const odapConstructor = {
name: "cactus-plugin#odapGateway",
dltIDs: ["dummy"],
Expand Down Expand Up @@ -57,9 +57,8 @@ test("dummy test for transfer commence flow", async (t: Test) => {
JSON.stringify(transferCommenceReq),
dummyPrivKeyStr,
);
t.doesNotThrow(
expect(
async () =>
await odapGateWay.lockEvidenceTransferCommence(transferCommenceReq),
"does not throw if lock evidence proccessed",
);
).not.toThrow();
});

0 comments on commit 713df91

Please sign in to comment.