mirror of
https://github.com/oceanprotocol-archive/squid-js.git
synced 2024-02-02 15:31:51 +01:00
Fix Reward condition pointing.
This commit is contained in:
parent
f002e5d616
commit
01465dc164
@ -113,7 +113,7 @@ describe("Consume Asset", () => {
|
|||||||
assert.isTrue(paid, "The asset has not been paid correctly")
|
assert.isTrue(paid, "The asset has not been paid correctly")
|
||||||
})
|
})
|
||||||
|
|
||||||
xit("should lock the payment", async () => {
|
xit("should grant the access", async () => {
|
||||||
const granted = await ocean.agreements.conditions
|
const granted = await ocean.agreements.conditions
|
||||||
.grantAccess(serviceAgreementSignatureResult.agreementId, ddo.id, consumer.getId(), publisher)
|
.grantAccess(serviceAgreementSignatureResult.agreementId, ddo.id, consumer.getId(), publisher)
|
||||||
|
|
||||||
|
@ -74,8 +74,8 @@ describe("Register Escrow Access Secret Store Template", () => {
|
|||||||
conditionIdEscrow = await escrowReward.generateIdHash(
|
conditionIdEscrow = await escrowReward.generateIdHash(
|
||||||
agreementId,
|
agreementId,
|
||||||
escrowAmount,
|
escrowAmount,
|
||||||
consumer.getId(),
|
|
||||||
publisher.getId(),
|
publisher.getId(),
|
||||||
|
consumer.getId(),
|
||||||
conditionIdLock,
|
conditionIdLock,
|
||||||
conditionIdAccess,
|
conditionIdAccess,
|
||||||
)
|
)
|
||||||
@ -147,8 +147,8 @@ describe("Register Escrow Access Secret Store Template", () => {
|
|||||||
const fulfill = await escrowReward.fulfill(
|
const fulfill = await escrowReward.fulfill(
|
||||||
agreementId,
|
agreementId,
|
||||||
escrowAmount,
|
escrowAmount,
|
||||||
consumer.getId(),
|
|
||||||
publisher.getId(),
|
publisher.getId(),
|
||||||
|
consumer.getId(),
|
||||||
conditionIdLock,
|
conditionIdLock,
|
||||||
conditionIdAccess,
|
conditionIdAccess,
|
||||||
consumer.getId(),
|
consumer.getId(),
|
||||||
|
@ -89,7 +89,7 @@ describe("Signature", () => {
|
|||||||
assert.equal(
|
assert.equal(
|
||||||
signature,
|
signature,
|
||||||
// tslint:disable-next-line
|
// tslint:disable-next-line
|
||||||
"0x842c61796f8dab8dc18ff7499a98054fcaeaddfd2384dbf7d545f00e8d44bb391a1dea96a4df692d9b9f141239024b9112cb1c815f9c4063d3a79ccf450abf3e1b",
|
"0x2164dd54b1df9908b3aa31a2d195c3e3a244ff62b51b0403958234f50cb313615ac5ca6660f7a76957612deeca84e6953f2ce74f56def351d9eb0f155a4eddff1c",
|
||||||
"The signatuere is not correct.",
|
"The signatuere is not correct.",
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
@ -105,8 +105,8 @@ export class EscrowAccessSecretStoreTemplate extends AgreementTemplate {
|
|||||||
const escrowRewardId = await escrowReward.generateIdHash(
|
const escrowRewardId = await escrowReward.generateIdHash(
|
||||||
agreementId,
|
agreementId,
|
||||||
amount,
|
amount,
|
||||||
from,
|
|
||||||
publisher,
|
publisher,
|
||||||
|
from,
|
||||||
lockRewardConditionId,
|
lockRewardConditionId,
|
||||||
accessSecretStoreConditionId,
|
accessSecretStoreConditionId,
|
||||||
)
|
)
|
||||||
|
@ -87,8 +87,8 @@ export default class OceanAgreementsConditions {
|
|||||||
const receipt = await escrowReward.fulfill(
|
const receipt = await escrowReward.fulfill(
|
||||||
agreementId,
|
agreementId,
|
||||||
amount,
|
amount,
|
||||||
consumer,
|
|
||||||
publisher,
|
publisher,
|
||||||
|
consumer,
|
||||||
conditionIdLock,
|
conditionIdLock,
|
||||||
conditionIdAccess,
|
conditionIdAccess,
|
||||||
from.getId(),
|
from.getId(),
|
||||||
|
Loading…
Reference in New Issue
Block a user