mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
and some more tests
This commit is contained in:
parent
2521866e92
commit
ca5e810eb2
@ -81,10 +81,10 @@ describe('Compute flow', () => {
|
|||||||
)
|
)
|
||||||
tokenAddress = await datatoken.create(
|
tokenAddress = await datatoken.create(
|
||||||
blob,
|
blob,
|
||||||
'AliceDT',
|
alice.getId(),
|
||||||
'DTA',
|
|
||||||
'10000000000',
|
'10000000000',
|
||||||
alice.getId()
|
'AliceDT',
|
||||||
|
'DTA'
|
||||||
)
|
)
|
||||||
assert(tokenAddress != null)
|
assert(tokenAddress != null)
|
||||||
})
|
})
|
||||||
|
@ -59,10 +59,10 @@ describe('Marketplace flow', () => {
|
|||||||
)
|
)
|
||||||
tokenAddress = await datatoken.create(
|
tokenAddress = await datatoken.create(
|
||||||
blob,
|
blob,
|
||||||
'AliceDT',
|
alice.getId(),
|
||||||
'DTA',
|
|
||||||
'10000000000',
|
'10000000000',
|
||||||
alice.getId()
|
'AliceDT',
|
||||||
|
'DTA'
|
||||||
)
|
)
|
||||||
assert(tokenAddress != null)
|
assert(tokenAddress != null)
|
||||||
})
|
})
|
||||||
|
@ -41,7 +41,7 @@ describe('Simple flow', () => {
|
|||||||
datatokensTemplate.abi as AbiItem[],
|
datatokensTemplate.abi as AbiItem[],
|
||||||
web3
|
web3
|
||||||
)
|
)
|
||||||
tokenAddress = await datatoken.create(blob, 'AliceDT', 'DTA', '10000000000', alice)
|
tokenAddress = await datatoken.create(blob, alice, '10000000000', 'AliceDT', 'DTA')
|
||||||
})
|
})
|
||||||
it('Alice mints 100 tokens', async () => {
|
it('Alice mints 100 tokens', async () => {
|
||||||
await datatoken.mint(tokenAddress, alice, tokenAmount)
|
await datatoken.mint(tokenAddress, alice, tokenAmount)
|
||||||
|
@ -81,10 +81,10 @@ describe('FixedRateExchange flow', () => {
|
|||||||
it('should create datatokens smart contract', async () => {
|
it('should create datatokens smart contract', async () => {
|
||||||
tokenAddress = await datatoken.create(
|
tokenAddress = await datatoken.create(
|
||||||
blob,
|
blob,
|
||||||
'AliceDT',
|
alice,
|
||||||
'DTA',
|
|
||||||
web3.utils.toWei('1000000000000000'),
|
web3.utils.toWei('1000000000000000'),
|
||||||
alice
|
'AliceDT',
|
||||||
|
'DTA'
|
||||||
)
|
)
|
||||||
assert(tokenAddress !== null)
|
assert(tokenAddress !== null)
|
||||||
if (consoleDebug) console.log("Alice's address:" + alice)
|
if (consoleDebug) console.log("Alice's address:" + alice)
|
||||||
@ -100,10 +100,10 @@ describe('FixedRateExchange flow', () => {
|
|||||||
)
|
)
|
||||||
oceanTokenAddress = await oceandatatoken.create(
|
oceanTokenAddress = await oceandatatoken.create(
|
||||||
blob,
|
blob,
|
||||||
'BobDT',
|
bob,
|
||||||
'DTB',
|
|
||||||
web3.utils.toWei('1000000000000000'),
|
web3.utils.toWei('1000000000000000'),
|
||||||
bob
|
'BobDT',
|
||||||
|
'DTB'
|
||||||
)
|
)
|
||||||
if (consoleDebug) console.log("Bob's address:" + bob)
|
if (consoleDebug) console.log("Bob's address:" + bob)
|
||||||
if (consoleDebug) console.log('oceanTokenAddress:' + oceanTokenAddress)
|
if (consoleDebug) console.log('oceanTokenAddress:' + oceanTokenAddress)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user