mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
update provider tests
This commit is contained in:
parent
456699f34d
commit
d91dd5a8a8
@ -39,6 +39,7 @@
|
||||
"test:unit": "npm run mocha -- 'test/unit/**/*.test.ts'",
|
||||
"test:unit:cover": "nyc --report-dir coverage/unit npm run test:unit",
|
||||
"test:integration": "npm run mocha -- 'test/integration/**/*.test.ts'",
|
||||
"test:provider": "npm run mocha -- 'test/integration/Provider.test.ts'",
|
||||
"test:integration:cover": "nyc --report-dir coverage/integration --no-clean npm run test:integration"
|
||||
},
|
||||
"repository": {
|
||||
|
@ -11,14 +11,17 @@ describe('Provider tests', () => {
|
||||
})
|
||||
|
||||
it('Alice tests invalid provider', async () => {
|
||||
const valid = await providerInstance.isValidProvider('http://example.net', fetchData)
|
||||
const valid = await providerInstance.isValidProvider(
|
||||
'http://example.net',
|
||||
crossFetchGeneric
|
||||
)
|
||||
assert(valid === false)
|
||||
})
|
||||
|
||||
it('Alice tests valid provider', async () => {
|
||||
const valid = await providerInstance.isValidProvider(
|
||||
'http://127.0.0.1:8030',
|
||||
fetchData
|
||||
crossFetchGeneric
|
||||
)
|
||||
assert(valid === true)
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user