1
0
mirror of https://github.com/oceanprotocol-archive/squid-js.git synced 2024-02-02 15:31:51 +01:00

fix tests

This commit is contained in:
Sebastian Gerske 2018-11-07 08:43:04 +01:00
parent edb2d43d99
commit c3282a97c6
3 changed files with 9 additions and 9 deletions

View File

@ -17,7 +17,7 @@ describe("DIDRegistry", () => {
before(async () => {
ConfigProvider.setConfig(config)
await ContractHandler.deployContracts()
await ContractHandler.prepareContracts()
ocean = await Ocean.getInstance(config)
didRegistry = await DIDRegistry.getInstance()
})

View File

@ -21,7 +21,7 @@ let accounts: Account[]
let publisherAccount: Account
let consumerAccount: Account
let serviceDefintion
let serviceDefinition
describe("ServiceAgreement", () => {
@ -44,7 +44,7 @@ describe("ServiceAgreement", () => {
const ddoConditions: DDOCondition[] = conditions.map((condition): DDOCondition => {
return {
name: condition.methodReflection.methodName,
timeout: 100,
timeout: condition.timeout,
conditionKey: condition.condtionKey,
parameters: condition.methodReflection.inputs.map((input) => {
return {
@ -55,7 +55,7 @@ describe("ServiceAgreement", () => {
} as DDOCondition
})
serviceDefintion = [
serviceDefinition = [
{
serviceDefinitionId: IdGenerator.generateId(),
templateId: serviceAgreementTemplate.getId(),
@ -65,12 +65,12 @@ describe("ServiceAgreement", () => {
})
describe("#createServiceAgreement()", () => {
describe("#signServiceAgreement()", () => {
it("should execute an service agreement", async () => {
const id: string = IdGenerator.generateId()
const did: string = `did:op:${id}`
const ddo = new DDO({id: did, service: serviceDefintion})
const ddo = new DDO({id: did, service: serviceDefinition})
const assetId: string = IdGenerator.generateId()
const serviceAgreementId: string = IdGenerator.generateId()
@ -92,7 +92,7 @@ describe("ServiceAgreement", () => {
const id: string = IdGenerator.generateId()
const did: string = `did:op:${id}`
const ddo = new DDO({id: did, service: serviceDefintion})
const ddo = new DDO({id: did, service: serviceDefinition})
const assetId: string = IdGenerator.generateId()
const serviceAgreementId: string = IdGenerator.generateId()
@ -113,7 +113,7 @@ describe("ServiceAgreement", () => {
const id: string = IdGenerator.generateId()
const did: string = `did:op:${id}`
const ddo = new DDO({id: did, service: serviceDefintion})
const ddo = new DDO({id: did, service: serviceDefinition})
const assetId: string = IdGenerator.generateId()
const serviceAgreementId: string = IdGenerator.generateId()

View File

@ -21,7 +21,7 @@ describe("ServiceAgreementTemplate", () => {
})
describe("#register()", () => {
it("should setup an agreement template", async () => {
it("should setup an Access agreement template correctly", async () => {
const templateOwner = accounts[0]
const serviceAgreementTemplate: ServiceAgreementTemplate =