Skip to content
This repository was archived by the owner on Dec 31, 2024. It is now read-only.

Commit 4ff3bc5

Browse files
committed
fix test exports
1 parent da91941 commit 4ff3bc5

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

index.js

+1
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,6 @@ module.exports = {
88
assertFail,
99
embarkConfig,
1010
deployLP,
11+
...contracts.test,
1112
},
1213
};

test/helpers/deployLP.js

+7-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,7 @@
11
const LiquidPledgingState = require('../../js/liquidPledgingState');
22

3-
const RecoveryVault = embark.require('Embark/contracts/RecoveryVault');
4-
const lpFactory = embark.require('Embark/contracts/LPFactory');
5-
const LPVault = embark.require('Embark/contracts/LPVault');
6-
const LiquidPledgingMock = embark.require('Embark/contracts/LiquidPledgingMock');
7-
const StandardTokenTest = embark.require('Embark/contracts/StandardToken');
8-
93
const embarkConfig = (additionalContracts = {}) => {
4+
if (!embark) throw new Error('embarkConfig can only be within the Embark framework');
105
const contracts = Object.assign(
116
{
127
RecoveryVault: {},
@@ -39,6 +34,12 @@ const embarkConfig = (additionalContracts = {}) => {
3934
};
4035

4136
const deploy = async () => {
37+
if (!embark) throw new Error('deployLP can only be within the Embark framework');
38+
const RecoveryVault = embark.require('Embark/contracts/RecoveryVault');
39+
const lpFactory = embark.require('Embark/contracts/LPFactory');
40+
const LPVault = embark.require('Embark/contracts/LPVault');
41+
const LiquidPledgingMock = embark.require('Embark/contracts/LiquidPledgingMock');
42+
const StandardTokenTest = embark.require('Embark/contracts/StandardToken');
4243
const accounts = await web3.eth.getAccounts();
4344
const giver1 = accounts[1];
4445

0 commit comments

Comments
 (0)