mirror of
https://github.com/oceanprotocol/ocean.js.git
synced 2024-11-26 20:39:05 +01:00
fix unit test
This commit is contained in:
parent
20a1a75bf8
commit
94dbfd190f
@ -14,7 +14,7 @@ matrix:
|
||||
|
||||
before_install:
|
||||
- npm install -g npm
|
||||
- npm install -g ganache-cli@~6.5.1
|
||||
- npm install -g ganache-cli@~6.7.0
|
||||
|
||||
before_script:
|
||||
- ganache-cli > ganache-cli.log &
|
||||
@ -22,7 +22,7 @@ before_script:
|
||||
script:
|
||||
- npm run lint
|
||||
- npm run build
|
||||
- npm run test
|
||||
- npm run test:unit
|
||||
|
||||
notifications:
|
||||
email: false
|
274
package-lock.json
generated
274
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@ -16,7 +16,7 @@
|
||||
"release": "release-it --non-interactive",
|
||||
"changelog": "auto-changelog -p",
|
||||
"prepublishOnly": "npm run build",
|
||||
"test": "mocha --config=test/unit/.mocharc.json --node-env=test --exit",
|
||||
"test:unit": "mocha --config=test/unit/.mocharc.json --node-env=test --exit test/unit/**/*.ts",
|
||||
"test:integration": "mocha --opts test/integration/mocha.opts"
|
||||
},
|
||||
"repository": {
|
||||
@ -43,8 +43,7 @@
|
||||
"uuid": "^8.0.0",
|
||||
"web3": "^1.2.9",
|
||||
"web3-eth-contract": "^1.2.9",
|
||||
"whatwg-url": "^8.0.0",
|
||||
"mocha": "^8.0.1"
|
||||
"whatwg-url": "^8.0.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@oceanprotocol/contracts": "^0.2.2",
|
||||
@ -73,8 +72,9 @@
|
||||
"ora": "^4.0.2",
|
||||
"prettier": "^2.0.5",
|
||||
"sinon": "^9.0.1",
|
||||
"source-map-support": "^0.5.16",
|
||||
"source-map-support": "^0.5.19",
|
||||
"ts-node": "^8.10.2",
|
||||
"ts-node-register": "^1.0.0",
|
||||
"typedoc": "^0.17.1",
|
||||
"typescript": "^3.9.5",
|
||||
"yargs": "^15.3.1"
|
||||
|
10
test/integration/.mocharc.json
Normal file
10
test/integration/.mocharc.json
Normal file
@ -0,0 +1,10 @@
|
||||
{
|
||||
"require": [
|
||||
"ts-node/register",
|
||||
"source-map-support/register",
|
||||
"mock-local-storage"
|
||||
],
|
||||
"full-trace": true,
|
||||
"exit": true,
|
||||
"timeout": "300000"
|
||||
}
|
@ -1,7 +0,0 @@
|
||||
--require ts-node/register
|
||||
--require source-map-support/register
|
||||
--require mock-local-storage
|
||||
--full-trace
|
||||
--exit
|
||||
--timeout 300000
|
||||
test/integration/**/*.test.ts
|
@ -1,12 +1,11 @@
|
||||
{
|
||||
"require": [
|
||||
"ts-node/register",
|
||||
"source-map-support/register",
|
||||
"mock-local-storage"
|
||||
],
|
||||
"full-trace": true,
|
||||
"bail": true,
|
||||
"exit": true,
|
||||
"timeout": 20000,
|
||||
"file": ["./test/unit/tsconfig.json", "./test/unit/DataTokens.test.ts"]
|
||||
{
|
||||
"require": [
|
||||
"ts-node/register",
|
||||
"source-map-support/register",
|
||||
"mock-local-storage"
|
||||
],
|
||||
"full-trace": true,
|
||||
"bail": true,
|
||||
"exit": true,
|
||||
"timeout": "20000"
|
||||
}
|
||||
|
@ -1,8 +1,9 @@
|
||||
import { assert } from 'chai'
|
||||
import { TestContractHandler } from '../TestContractHandler'
|
||||
import { DataTokens } from '../../src/datatokens/Datatokens'
|
||||
import Web3 from 'web3'
|
||||
|
||||
|
||||
const Web3 = require('web3')
|
||||
const factory = require('@oceanprotocol/contracts/artifacts/development/Factory.json')
|
||||
const datatokensTemplate = require('@oceanprotocol/contracts/artifacts/development/DataTokenTemplate.json')
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user