@@ -169,49 +169,51 @@ export default function shouldBehaveLikeCodexTitle(accounts, metadata, feesEnabl
169169 } )
170170 } )
171171
172- describe ( 'metadata' , function ( ) {
173- it ( 'should have the correct name' , async function ( ) {
174- const name = await this . token . name ( )
175- name . should . be . equal ( 'Codex Title' )
176- } )
177-
178- it ( 'should have the correct symbol' , async function ( ) {
179- const symbol = await this . token . symbol ( )
180- symbol . should . be . equal ( 'CT' )
181- } )
182-
183- describe ( 'tokenURI' , function ( ) {
184- it ( 'should be empty by default' , async function ( ) {
185- const tokenURI = await this . token . tokenURI ( firstTokenId )
186- tokenURI . should . be . equal ( '' )
172+ if ( ! feesEnabled ) {
173+ describe ( 'metadata' , function ( ) {
174+ it ( 'should have the correct name' , async function ( ) {
175+ const name = await this . token . name ( )
176+ name . should . be . equal ( 'Codex Title' )
187177 } )
188178
189- describe ( 'tokenURIPrefix' , function ( ) {
190- const constantTokenURIPrefix = 'https://codexprotocol.com/token/'
179+ it ( 'should have the correct symbol' , async function ( ) {
180+ const symbol = await this . token . symbol ( )
181+ symbol . should . be . equal ( 'CT' )
182+ } )
191183
184+ describe ( 'tokenURI' , function ( ) {
192185 it ( 'should be empty by default' , async function ( ) {
193- const tokenURIPrefix = await this . token . tokenURIPrefix ( )
194- tokenURIPrefix . should . be . equal ( '' )
186+ const tokenURI = await this . token . tokenURI ( firstTokenId )
187+ tokenURI . should . be . equal ( '' )
195188 } )
196189
197- describe ( 'when set by an address that is not the owner' , function ( ) {
198- it ( 'should fail' , async function ( ) {
199- await assertRevert ( this . token . setTokenURIPrefix ( constantTokenURIPrefix , { from : unauthorized } ) )
190+ describe ( 'tokenURIPrefix' , function ( ) {
191+ const constantTokenURIPrefix = 'https://codexprotocol.com/token/'
192+
193+ it ( 'should be empty by default' , async function ( ) {
194+ const tokenURIPrefix = await this . token . tokenURIPrefix ( )
195+ tokenURIPrefix . should . be . equal ( '' )
200196 } )
201- } )
202197
203- describe ( 'when called by the owner' , function ( ) {
204- beforeEach ( async function ( ) {
205- await this . token . setTokenURIPrefix ( constantTokenURIPrefix )
198+ describe ( 'when set by an address that is not the owner' , function ( ) {
199+ it ( 'should fail' , async function ( ) {
200+ await assertRevert ( this . token . setTokenURIPrefix ( constantTokenURIPrefix , { from : unauthorized } ) )
201+ } )
206202 } )
207203
208- it ( 'should update the URI for all tokens' , async function ( ) {
209- const tokenURI = await this . token . tokenURI ( firstTokenId )
210- tokenURI . should . be . equal ( `${ constantTokenURIPrefix } ${ firstTokenId } ` )
204+ describe ( 'when called by the owner' , function ( ) {
205+ beforeEach ( async function ( ) {
206+ await this . token . setTokenURIPrefix ( constantTokenURIPrefix )
207+ } )
208+
209+ it ( 'should update the URI for all tokens' , async function ( ) {
210+ const tokenURI = await this . token . tokenURI ( firstTokenId )
211+ tokenURI . should . be . equal ( `${ constantTokenURIPrefix } ${ firstTokenId } ` )
212+ } )
211213 } )
212214 } )
213215 } )
214216 } )
215- } )
217+ }
216218 } )
217219}
0 commit comments