-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #153 from lenkan/update-workflow
add npm ci, linting, format check to workflow
- Loading branch information
Showing
22 changed files
with
269 additions
and
116 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,29 +1,33 @@ | ||
import { SignifyClient } from "signify-ts"; | ||
import { getOrCreateClients, getOrCreateContact, getOrCreateIdentifier } from "./utils/test-setup"; | ||
import { SignifyClient } from 'signify-ts'; | ||
import { | ||
getOrCreateClients, | ||
getOrCreateContact, | ||
getOrCreateIdentifier, | ||
} from './utils/test-setup'; | ||
|
||
let client1: SignifyClient, client2: SignifyClient; | ||
let name1_id: string, name1_oobi: string; | ||
let name2_id: string, name2_oobi: string; | ||
let contact1_id: string, contact2_id: string;; | ||
let contact1_id: string, contact2_id: string; | ||
|
||
beforeAll(async () => { | ||
// create two clients with random secrets | ||
[client1, client2] = await getOrCreateClients(2); | ||
}); | ||
beforeAll(async () => { | ||
[name1_id, name1_oobi] = await getOrCreateIdentifier(client1, "name1"); | ||
[name2_id, name2_oobi] = await getOrCreateIdentifier(client2, "name2"); | ||
[name1_id, name1_oobi] = await getOrCreateIdentifier(client1, 'name1'); | ||
[name2_id, name2_oobi] = await getOrCreateIdentifier(client2, 'name2'); | ||
}); | ||
beforeAll(async () => { | ||
contact1_id = await getOrCreateContact(client2, "contact1", name1_oobi); | ||
contact2_id = await getOrCreateContact(client1, "contact2", name2_oobi); | ||
contact1_id = await getOrCreateContact(client2, 'contact1', name1_oobi); | ||
contact2_id = await getOrCreateContact(client1, 'contact2', name2_oobi); | ||
}); | ||
|
||
describe("test-setup-clients", () => { | ||
test("step1", async () => { | ||
describe('test-setup-clients', () => { | ||
test('step1', async () => { | ||
expect(name1_id).toEqual(contact1_id); | ||
}); | ||
test("step2", async () => { | ||
test('step2', async () => { | ||
expect(name2_id).toEqual(contact2_id); | ||
}); | ||
}); |
62 changes: 41 additions & 21 deletions
62
examples/integration-scripts/test-setup-single-client.test.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.