aboutsummaryrefslogtreecommitdiffstats
path: root/packages/connect/test/fixtures
diff options
context:
space:
mode:
authorfragosti <francesco.agosti93@gmail.com>2018-08-15 05:40:52 +0800
committerfragosti <francesco.agosti93@gmail.com>2018-08-15 05:40:52 +0800
commitce88086e080e05ed71c1ef4e31f2d0ce530af67f (patch)
treef2022bb7bc42c9bc85cbef19c684b666e2d7f66f /packages/connect/test/fixtures
parentc1cc92a46f9ebfa4408a5dc515f1e100fe3a7054 (diff)
downloaddexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar.gz
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar.bz2
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar.lz
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar.xz
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.tar.zst
dexon-sol-tools-ce88086e080e05ed71c1ef4e31f2d0ce530af67f.zip
Update types to reflect v2
Diffstat (limited to 'packages/connect/test/fixtures')
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/fees.ts4
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.json8
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.ts8
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/orderbook.json16
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/orderbook.ts16
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/orders.json8
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/orders.ts8
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/snapshot_orderbook_channel_message.ts17
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/token_pairs.json4
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/token_pairs.ts6
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/unknown_orderbook_channel_message.ts2
-rw-r--r--packages/connect/test/fixtures/standard_relayer_api/update_orderbook_channel_message.ts4
12 files changed, 42 insertions, 59 deletions
diff --git a/packages/connect/test/fixtures/standard_relayer_api/fees.ts b/packages/connect/test/fixtures/standard_relayer_api/fees.ts
index fecbaacff..7a526b491 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/fees.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/fees.ts
@@ -1,8 +1,8 @@
import { BigNumber } from '@0xproject/utils';
-import { FeesResponse } from '../../../src/types';
+import { OrderConfigResponse } from '../../../src/types';
-export const feesResponse: FeesResponse = {
+export const feesResponse: OrderConfigResponse = {
feeRecipient: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
makerFee: new BigNumber('10000000000000000'),
takerFee: new BigNumber('30000000000000000'),
diff --git a/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.json b/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.json
index e84954b0d..23e4fb327 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.json
+++ b/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.json
@@ -3,14 +3,14 @@
"taker": "0xa2b31dacf30a9c50ca473337c01d8a201ae33e32",
"makerFee": "100000000000000",
"takerFee": "200000000000000",
- "makerTokenAmount": "10000000000000000",
- "takerTokenAmount": "20000000000000000",
+ "makerAssetAmount": "10000000000000000",
+ "takerAssetAmount": "20000000000000000",
"makerTokenAddress": "0x323b5d4c32345ced77393b3530b1eed0f346429d",
"takerTokenAddress": "0xef7fff64389b814a946f3e92105513705ca6b990",
"salt": "256",
"feeRecipient": "0xb046140686d052fff581f63f8136cce132e857da",
- "exchangeContractAddress": "0x12459c951127e0c374ff9105dda097662a027093",
- "expirationUnixTimestampSec": "42",
+ "exchangeAddress": "0x12459c951127e0c374ff9105dda097662a027093",
+ "expirationTimeSeconds": "42",
"ecSignature": {
"v": 27,
"r": "0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33",
diff --git a/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.ts b/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.ts
index 5a03a2ff6..68446c83a 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/order/0xabc67323774bdbd24d94f977fa9ac94a50f016026fd13f42990861238897721f.ts
@@ -5,14 +5,14 @@ export const orderResponse = {
taker: '0xa2b31dacf30a9c50ca473337c01d8a201ae33e32',
makerFee: new BigNumber('100000000000000'),
takerFee: new BigNumber('200000000000000'),
- makerTokenAmount: new BigNumber('10000000000000000'),
- takerTokenAmount: new BigNumber('20000000000000000'),
+ makerAssetAmount: new BigNumber('10000000000000000'),
+ takerAssetAmount: new BigNumber('20000000000000000'),
makerTokenAddress: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
takerTokenAddress: '0xef7fff64389b814a946f3e92105513705ca6b990',
salt: new BigNumber('256'),
feeRecipient: '0xb046140686d052fff581f63f8136cce132e857da',
- exchangeContractAddress: '0x12459c951127e0c374ff9105dda097662a027093',
- expirationUnixTimestampSec: new BigNumber('42'),
+ exchangeAddress: '0x12459c951127e0c374ff9105dda097662a027093',
+ expirationTimeSeconds: new BigNumber('42'),
ecSignature: {
v: 27,
r: '0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33',
diff --git a/packages/connect/test/fixtures/standard_relayer_api/orderbook.json b/packages/connect/test/fixtures/standard_relayer_api/orderbook.json
index 825be34c2..2dec4b0fe 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/orderbook.json
+++ b/packages/connect/test/fixtures/standard_relayer_api/orderbook.json
@@ -5,14 +5,14 @@
"taker": "0xa2b31dacf30a9c50ca473337c01d8a201ae33e32",
"makerFee": "100000000000000",
"takerFee": "200000000000000",
- "makerTokenAmount": "10000000000000000",
- "takerTokenAmount": "20000000000000000",
+ "makerAssetAmount": "10000000000000000",
+ "takerAssetAmount": "20000000000000000",
"makerTokenAddress": "0x323b5d4c32345ced77393b3530b1eed0f346429d",
"takerTokenAddress": "0xef7fff64389b814a946f3e92105513705ca6b990",
"salt": "256",
"feeRecipient": "0xb046140686d052fff581f63f8136cce132e857da",
- "exchangeContractAddress": "0x12459c951127e0c374ff9105dda097662a027093",
- "expirationUnixTimestampSec": "42",
+ "exchangeAddress": "0x12459c951127e0c374ff9105dda097662a027093",
+ "expirationTimeSeconds": "42",
"ecSignature": {
"v": 27,
"r": "0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33",
@@ -26,14 +26,14 @@
"taker": "0xa2b31dacf30a9c50ca473337c01d8a201ae33e32",
"makerFee": "100000000000000",
"takerFee": "200000000000000",
- "makerTokenAmount": "10000000000000000",
- "takerTokenAmount": "20000000000000000",
+ "makerAssetAmount": "10000000000000000",
+ "takerAssetAmount": "20000000000000000",
"makerTokenAddress": "0x323b5d4c32345ced77393b3530b1eed0f346429d",
"takerTokenAddress": "0xef7fff64389b814a946f3e92105513705ca6b990",
"salt": "256",
"feeRecipient": "0xb046140686d052fff581f63f8136cce132e857da",
- "exchangeContractAddress": "0x12459c951127e0c374ff9105dda097662a027093",
- "expirationUnixTimestampSec": "42",
+ "exchangeAddress": "0x12459c951127e0c374ff9105dda097662a027093",
+ "expirationTimeSeconds": "42",
"ecSignature": {
"v": 27,
"r": "0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33",
diff --git a/packages/connect/test/fixtures/standard_relayer_api/orderbook.ts b/packages/connect/test/fixtures/standard_relayer_api/orderbook.ts
index 6684ac2e5..9f80988ce 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/orderbook.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/orderbook.ts
@@ -7,14 +7,14 @@ export const orderbookResponse = {
taker: '0xa2b31dacf30a9c50ca473337c01d8a201ae33e32',
makerFee: new BigNumber('100000000000000'),
takerFee: new BigNumber('200000000000000'),
- makerTokenAmount: new BigNumber('10000000000000000'),
- takerTokenAmount: new BigNumber('20000000000000000'),
+ makerAssetAmount: new BigNumber('10000000000000000'),
+ takerAssetAmount: new BigNumber('20000000000000000'),
makerTokenAddress: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
takerTokenAddress: '0xef7fff64389b814a946f3e92105513705ca6b990',
salt: new BigNumber('256'),
feeRecipient: '0xb046140686d052fff581f63f8136cce132e857da',
- exchangeContractAddress: '0x12459c951127e0c374ff9105dda097662a027093',
- expirationUnixTimestampSec: new BigNumber('42'),
+ exchangeAddress: '0x12459c951127e0c374ff9105dda097662a027093',
+ expirationTimeSeconds: new BigNumber('42'),
ecSignature: {
v: 27,
r: '0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33',
@@ -28,14 +28,14 @@ export const orderbookResponse = {
taker: '0xa2b31dacf30a9c50ca473337c01d8a201ae33e32',
makerFee: new BigNumber('100000000000000'),
takerFee: new BigNumber('200000000000000'),
- makerTokenAmount: new BigNumber('10000000000000000'),
- takerTokenAmount: new BigNumber('20000000000000000'),
+ makerAssetAmount: new BigNumber('10000000000000000'),
+ takerAssetAmount: new BigNumber('20000000000000000'),
makerTokenAddress: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
takerTokenAddress: '0xef7fff64389b814a946f3e92105513705ca6b990',
salt: new BigNumber('256'),
feeRecipient: '0xb046140686d052fff581f63f8136cce132e857da',
- exchangeContractAddress: '0x12459c951127e0c374ff9105dda097662a027093',
- expirationUnixTimestampSec: new BigNumber('42'),
+ exchangeAddress: '0x12459c951127e0c374ff9105dda097662a027093',
+ expirationTimeSeconds: new BigNumber('42'),
ecSignature: {
v: 27,
r: '0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33',
diff --git a/packages/connect/test/fixtures/standard_relayer_api/orders.json b/packages/connect/test/fixtures/standard_relayer_api/orders.json
index cfa780dc4..929dde4a8 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/orders.json
+++ b/packages/connect/test/fixtures/standard_relayer_api/orders.json
@@ -4,14 +4,14 @@
"taker": "0xa2b31dacf30a9c50ca473337c01d8a201ae33e32",
"makerFee": "100000000000000",
"takerFee": "200000000000000",
- "makerTokenAmount": "10000000000000000",
- "takerTokenAmount": "20000000000000000",
+ "makerAssetAmount": "10000000000000000",
+ "takerAssetAmount": "20000000000000000",
"makerTokenAddress": "0x323b5d4c32345ced77393b3530b1eed0f346429d",
"takerTokenAddress": "0xef7fff64389b814a946f3e92105513705ca6b990",
"salt": "256",
"feeRecipient": "0x9e56625509c2f60af937f23b7b532600390e8c8b",
- "exchangeContractAddress": "0x9e56625509c2f60af937f23b7b532600390e8c8b",
- "expirationUnixTimestampSec": "42",
+ "exchangeAddress": "0x9e56625509c2f60af937f23b7b532600390e8c8b",
+ "expirationTimeSeconds": "42",
"ecSignature": {
"v": 27,
"r": "0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33",
diff --git a/packages/connect/test/fixtures/standard_relayer_api/orders.ts b/packages/connect/test/fixtures/standard_relayer_api/orders.ts
index 5044777bd..6d32fd3f3 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/orders.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/orders.ts
@@ -6,14 +6,14 @@ export const ordersResponse = [
taker: '0xa2b31dacf30a9c50ca473337c01d8a201ae33e32',
makerFee: new BigNumber('100000000000000'),
takerFee: new BigNumber('200000000000000'),
- makerTokenAmount: new BigNumber('10000000000000000'),
- takerTokenAmount: new BigNumber('20000000000000000'),
+ makerAssetAmount: new BigNumber('10000000000000000'),
+ takerAssetAmount: new BigNumber('20000000000000000'),
makerTokenAddress: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
takerTokenAddress: '0xef7fff64389b814a946f3e92105513705ca6b990',
salt: new BigNumber('256'),
feeRecipient: '0x9e56625509c2f60af937f23b7b532600390e8c8b',
- exchangeContractAddress: '0x9e56625509c2f60af937f23b7b532600390e8c8b',
- expirationUnixTimestampSec: new BigNumber('42'),
+ exchangeAddress: '0x9e56625509c2f60af937f23b7b532600390e8c8b',
+ expirationTimeSeconds: new BigNumber('42'),
ecSignature: {
v: 27,
r: '0x61a3ed31b43c8780e905a260a35faefcc527be7516aa11c0256729b5b351bc33',
diff --git a/packages/connect/test/fixtures/standard_relayer_api/snapshot_orderbook_channel_message.ts b/packages/connect/test/fixtures/standard_relayer_api/snapshot_orderbook_channel_message.ts
deleted file mode 100644
index 1d7e67055..000000000
--- a/packages/connect/test/fixtures/standard_relayer_api/snapshot_orderbook_channel_message.ts
+++ /dev/null
@@ -1,17 +0,0 @@
-import * as orderbookJSON from './orderbook.json';
-
-const orderbookJsonString = JSON.stringify(orderbookJSON);
-
-export const snapshotOrderbookChannelMessage = `{
- "type": "snapshot",
- "channel": "orderbook",
- "requestId": 1,
- "payload": ${orderbookJsonString}
-}`;
-
-export const malformedSnapshotOrderbookChannelMessage = `{
- "type": "snapshot",
- "channel": "orderbook",
- "requestId": 1,
- "payload": {}
-}`;
diff --git a/packages/connect/test/fixtures/standard_relayer_api/token_pairs.json b/packages/connect/test/fixtures/standard_relayer_api/token_pairs.json
index 90f57a974..2d9610e3d 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/token_pairs.json
+++ b/packages/connect/test/fixtures/standard_relayer_api/token_pairs.json
@@ -1,12 +1,12 @@
[
{
- "tokenA": {
+ "assetDataA": {
"address": "0x323b5d4c32345ced77393b3530b1eed0f346429d",
"minAmount": "0",
"maxAmount": "10000000000000000000",
"precision": 5
},
- "tokenB": {
+ "assetDataB": {
"address": "0xef7fff64389b814a946f3e92105513705ca6b990",
"minAmount": "0",
"maxAmount": "50000000000000000000",
diff --git a/packages/connect/test/fixtures/standard_relayer_api/token_pairs.ts b/packages/connect/test/fixtures/standard_relayer_api/token_pairs.ts
index f48b1e877..1225ac4fc 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/token_pairs.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/token_pairs.ts
@@ -2,15 +2,15 @@ import { BigNumber } from '@0xproject/utils';
import { TokenPairsItem } from '../../../src/types';
-export const tokenPairsResponse: TokenPairsItem[] = [
+export const assetDataPairsResponse: TokenPairsItem[] = [
{
- tokenA: {
+ assetDataA: {
address: '0x323b5d4c32345ced77393b3530b1eed0f346429d',
minAmount: new BigNumber(0),
maxAmount: new BigNumber('10000000000000000000'),
precision: 5,
},
- tokenB: {
+ assetDataB: {
address: '0xef7fff64389b814a946f3e92105513705ca6b990',
minAmount: new BigNumber(0),
maxAmount: new BigNumber('50000000000000000000'),
diff --git a/packages/connect/test/fixtures/standard_relayer_api/unknown_orderbook_channel_message.ts b/packages/connect/test/fixtures/standard_relayer_api/unknown_orderbook_channel_message.ts
index cbedff60e..c0e924a4b 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/unknown_orderbook_channel_message.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/unknown_orderbook_channel_message.ts
@@ -2,7 +2,7 @@ import * as orderResponseJSON from './order/0xabc67323774bdbd24d94f977fa9ac94a50
const orderJSONString = JSON.stringify(orderResponseJSON);
-export const unknownOrderbookChannelMessage = `{
+export const unknownOrdersChannelMessage = `{
"type": "superGoodUpdate",
"channel": "orderbook",
"requestId": 1,
diff --git a/packages/connect/test/fixtures/standard_relayer_api/update_orderbook_channel_message.ts b/packages/connect/test/fixtures/standard_relayer_api/update_orderbook_channel_message.ts
index 0e2c7523b..daab20368 100644
--- a/packages/connect/test/fixtures/standard_relayer_api/update_orderbook_channel_message.ts
+++ b/packages/connect/test/fixtures/standard_relayer_api/update_orderbook_channel_message.ts
@@ -2,14 +2,14 @@ import * as orderResponseJSON from './order/0xabc67323774bdbd24d94f977fa9ac94a50
const orderJSONString = JSON.stringify(orderResponseJSON);
-export const updateOrderbookChannelMessage = `{
+export const updateOrdersChannelMessage = `{
"type": "update",
"channel": "orderbook",
"requestId": 1,
"payload": ${orderJSONString}
}`;
-export const malformedUpdateOrderbookChannelMessage = `{
+export const malformedUpdateOrdersChannelMessage = `{
"type": "update",
"channel": "orderbook",
"requestId": 1,