@@ -2,7 +2,6 @@ const { assertRevert } = require('../../helpers/assertRevert');
22const { shouldBehaveLikeERC721 } = require ( './ERC721.behavior' ) ;
33const { shouldBehaveLikeMintAndBurnERC721 } = require ( './ERC721MintBurn.behavior' ) ;
44const { shouldSupportInterfaces } = require ( '../../introspection/SupportsInterface.behavior' ) ;
5- const _ = require ( 'lodash' ) ;
65
76const BigNumber = web3 . BigNumber ;
87const ERC721FullMock = artifacts . require ( 'ERC721FullMock.sol' ) ;
@@ -173,7 +172,9 @@ contract('ERC721Full', function ([
173172
174173 it ( 'returns correct token IDs for target' , async function ( ) {
175174 ( await this . token . balanceOf ( another ) ) . toNumber ( ) . should . be . equal ( 2 ) ;
176- const tokensListed = await Promise . all ( _ . range ( 2 ) . map ( i => this . token . tokenOfOwnerByIndex ( another , i ) ) ) ;
175+ const tokensListed = await Promise . all (
176+ [ 0 , 1 ] . map ( i => this . token . tokenOfOwnerByIndex ( another , i ) )
177+ ) ;
177178 tokensListed . map ( t => t . toNumber ( ) ) . should . have . members ( [ firstTokenId , secondTokenId ] ) ;
178179 } ) ;
179180
@@ -186,7 +187,9 @@ contract('ERC721Full', function ([
186187
187188 describe ( 'tokenByIndex' , function ( ) {
188189 it ( 'should return all tokens' , async function ( ) {
189- const tokensListed = await Promise . all ( _ . range ( 2 ) . map ( i => this . token . tokenByIndex ( i ) ) ) ;
190+ const tokensListed = await Promise . all (
191+ [ 0 , 1 ] . map ( i => this . token . tokenByIndex ( i ) )
192+ ) ;
190193 tokensListed . map ( t => t . toNumber ( ) ) . should . have . members ( [ firstTokenId , secondTokenId ] ) ;
191194 } ) ;
192195
@@ -205,9 +208,10 @@ contract('ERC721Full', function ([
205208
206209 ( await this . token . totalSupply ( ) ) . toNumber ( ) . should . be . equal ( 3 ) ;
207210
208- const tokensListed = await Promise . all ( _ . range ( 3 ) . map ( i => this . token . tokenByIndex ( i ) ) ) ;
209- const expectedTokens = _ . filter (
210- [ firstTokenId , secondTokenId , newTokenId , anotherNewTokenId ] ,
211+ const tokensListed = await Promise . all (
212+ [ 0 , 1 , 2 ] . map ( i => this . token . tokenByIndex ( i ) )
213+ ) ;
214+ const expectedTokens = [ firstTokenId , secondTokenId , newTokenId , anotherNewTokenId ] . filter (
211215 x => ( x !== tokenId )
212216 ) ;
213217 tokensListed . map ( t => t . toNumber ( ) ) . should . have . members ( expectedTokens ) ;
0 commit comments