-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
adds client interoperability for apis
- Loading branch information
Showing
4 changed files
with
68 additions
and
22 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { fetchActiveWallets, setup } from '../../api'; | ||
import { getDeviceId } from '../utils/getters'; | ||
import { setupTestClient } from '../utils/helpers'; | ||
import { getStoredClient, setStoredClient } from '../utils/setup'; | ||
|
||
/** | ||
* This test is used to test the interoperability between the Class-based API and the Functional API. | ||
*/ | ||
describe('client interop', () => { | ||
it('should setup the Client, then use that client data to', async () => { | ||
const client = setupTestClient(); | ||
const isPaired = await client.connect(getDeviceId()); | ||
expect(isPaired).toBe(true); | ||
|
||
await setup({ | ||
getStoredClient, | ||
setStoredClient, | ||
}); | ||
|
||
const activeWallets = await fetchActiveWallets(); | ||
expect(activeWallets).toBeTruthy(); | ||
}); | ||
}); |
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