* add LibERC721Order.sol * Add ERC721 interface to vendor/ * Add ERC721OrdersFeature interface * Storage lib for ERC721 orders feature * Implement basic functionality for ERC721 orders (buy, sell, cancel, etc) * Add isValidERC721OrderSignature to interface * implement onERC721Received * Implement batchBuyERC721s * left/right orders -> sell/buy orders * Add missing @return comments * Implement matching functions * Use SafeMath where necessary * add rich errors for ERC721OrdersFeature * Add comments * Add presign support for ERC721 orders * Cancel using just the order nonce * Add IERC721OrdersFeature to IZeroEx * Add taker callback * Assembly optimizations in LibERC721Order * Add ERC721Orders TS class * create zero-ex/contracts/test/integration/ and tokens/ directories * TestMintableERC721Token * tmp * address feedback from original PR (#391) * address feedback from original PR * Update contracts/zero-ex/contracts/src/features/ERC721OrdersFeature.sol Co-authored-by: Kim Persson <kimpers@users.noreply.github.com> * address review feedback and improve order parameter naming * Add batchCancel function * Emit order fields in preSign * Fix tests Co-authored-by: Lawrence Forman <me@merklejerk.com> Co-authored-by: Kim Persson <kimpers@users.noreply.github.com> Co-authored-by: Michael Zhu <mchl.zhu.96@gmail.com> * Remove revertIfIncomplete from batchMatch * Sanity check maker address in preSign * ERC1155OrdersFeature contracts * Commence refactor, abstract base contract * ERC721OrdersFeature inherits from NFTOrders * Refactor ERC1155OrdersFeature to inherit from NFTOrders * Fix order hashing * Fix ERC721OrdersFeature tests * Typos * Remove maker address from preSigned mapping * disable dex sampler tests * Refactor TS tooling * Address PR feedback * Rearrange event fields to better align with struct fields * Update comments * update AbiEncoder.create params * Add ERC1155Order to protocol-utils * Add ERC1155OrdersFeeature tests * Bump package versions and regenerate contract wrappers * Add ERC165Feature * NFT orders: address audit findings (#417) * CVF-1: use pragma solidity ^0.6 instead of ^0.6.5 * CVF-11: fix inaccurate comment * CVF-16: Enable taker callbacks for batchBuyERC1155s * CVF-17: use internal call if revertIfIncomplete is true * CVF-21: avoid duplicate SLOAD * CVF-23: merge if statements * CVF-24: Reorder status checks to be consistent with ERC721OrdersFeature * CVF-25: Update unclear comment (canonical hash -> EIP-712 hash) * CVF-31: Document keys of orderState mapping * CVF-45: DRY up fees/properties hashing * CVF-47, CVF-50, CVF-57: calculate properties.length once; hash propertyStructHashArray in-place using assembly * CVF-56: More descriptive names for assembly variables * CVF-71: Update confusing comment about rounding in _payFees * CVF-72: Move ETH assertions outside of loop in _payFees * CVF-74: Move property validation loop to else branch * CVF-82: Update inaccurate comment * CVF-86: Enable taker callbacks for batchBuyERC721s * CVF-87: use internal call if revertIfIncomplete is true * CVF-89: Perform token mismatch checks before stateful operations * CVF-90, CVF-91: Defer ERC20 token mismatch check * CVF-93: Add inline comments for _payFees parameters in matchERC721Orders * CVF-94: Fix comment (Step 7 -> Step 5) * CVF-98: Use binary & operator instead of mod * CVF-99: Update unclear comment (canonical hash -> EIP-712 hash) * CVF-65, CVF-66, CVF-67: Copy params.ethAvailable into local variable; check that ethSpent does not exceed ethAvailable; remove ethAvailable < erc20FillAmount check * CVF-52, CVF-55, CVF-59: calculate fees.length once; hash feeStructHashArray in-place using assembly * CVF-14, CVF-32: OrderState struct; separate storage mapping for 1155 cancellations so orders can be cancelled by nonce * Update changelogs, IZeroEx artifact/wrapper Co-authored-by: Lawrence Forman <lawrence@0xproject.com> Co-authored-by: Lawrence Forman <me@merklejerk.com> Co-authored-by: Kim Persson <kimpers@users.noreply.github.com>
83 lines
2.9 KiB
JSON
83 lines
2.9 KiB
JSON
{
|
|
"name": "@0x/contracts-test-utils",
|
|
"version": "5.4.16",
|
|
"engines": {
|
|
"node": ">=6.12"
|
|
},
|
|
"description": "Test utils for 0x contracts",
|
|
"main": "lib/src/index.js",
|
|
"directories": {
|
|
"test": "test"
|
|
},
|
|
"scripts": {
|
|
"build": "tsc -b",
|
|
"build:ci": "yarn build",
|
|
"test": "yarn run_mocha",
|
|
"test:coverage": "run-s build run_mocha coverage:report:text coverage:report:lcov",
|
|
"run_mocha": "mocha --require source-map-support/register --require make-promises-safe 'lib/test/**/*.js' --timeout 100000 --bail --exit",
|
|
"clean": "shx rm -rf lib",
|
|
"lint": "tslint --format stylish --project tsconfig.lint.json",
|
|
"fix": "tslint --fix --format stylish --project tsconfig.lint.json",
|
|
"coverage:report:text": "istanbul report text",
|
|
"coverage:report:html": "istanbul report html && open coverage/index.html",
|
|
"profiler:report:html": "istanbul report html && open coverage/index.html",
|
|
"coverage:report:lcov": "istanbul report lcov",
|
|
"test:circleci": "yarn test"
|
|
},
|
|
"repository": {
|
|
"type": "git",
|
|
"url": "https://github.com/0xProject/protocol.git"
|
|
},
|
|
"license": "Apache-2.0",
|
|
"bugs": {
|
|
"url": "https://github.com/0xProject/protocol/issues"
|
|
},
|
|
"homepage": "https://github.com/0xProject/protocol/tree/main/contracts/test-utils",
|
|
"devDependencies": {
|
|
"@0x/sol-compiler": "^4.7.8",
|
|
"@0x/tslint-config": "^4.1.4",
|
|
"npm-run-all": "^4.1.2",
|
|
"shx": "^0.2.2",
|
|
"tslint": "5.11.0",
|
|
"typescript": "4.2.2"
|
|
},
|
|
"dependencies": {
|
|
"@0x/assert": "^3.0.31",
|
|
"@0x/base-contract": "^6.4.5",
|
|
"@0x/contract-addresses": "^6.11.0",
|
|
"@0x/dev-utils": "^4.2.11",
|
|
"@0x/json-schemas": "^6.4.1",
|
|
"@0x/order-utils": "^10.4.28",
|
|
"@0x/sol-coverage": "^4.0.42",
|
|
"@0x/sol-profiler": "^4.1.32",
|
|
"@0x/sol-trace": "^3.0.42",
|
|
"@0x/subproviders": "^6.6.2",
|
|
"@0x/types": "^3.3.4",
|
|
"@0x/typescript-typings": "^5.2.1",
|
|
"@0x/utils": "^6.5.0",
|
|
"@0x/web3-wrapper": "^7.6.2",
|
|
"@types/bn.js": "^4.11.0",
|
|
"@types/js-combinatorics": "^0.5.29",
|
|
"@types/lodash": "4.14.104",
|
|
"@types/mocha": "^5.2.7",
|
|
"@types/node": "12.12.54",
|
|
"bn.js": "^4.11.8",
|
|
"chai": "^4.0.1",
|
|
"chai-as-promised": "^7.1.0",
|
|
"chai-bignumber": "^3.0.0",
|
|
"decimal.js": "^10.2.0",
|
|
"dirty-chai": "^2.0.1",
|
|
"ethereum-types": "^3.6.0",
|
|
"ethereumjs-util": "^7.0.10",
|
|
"ethers": "~4.0.4",
|
|
"js-combinatorics": "^0.5.3",
|
|
"lodash": "^4.17.11",
|
|
"make-promises-safe": "^1.1.0",
|
|
"mocha": "^6.2.0"
|
|
},
|
|
"publishConfig": {
|
|
"access": "public"
|
|
},
|
|
"gitHead": "4f91bfd907996b2f4dd383778b50c479c2602b56"
|
|
}
|