File tree Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Expand file tree Collapse file tree 1 file changed +9
-1
lines changed Original file line number Diff line number Diff line change @@ -178,14 +178,22 @@ contract('VanityURL', function(accounts) {
178
178
} )
179
179
} ) ;
180
180
181
- it ( "should error on change vanityURL when not assigned " , function ( ) {
181
+ it ( "should error on change vanityURL when address has no vanity " , function ( ) {
182
182
return vanityInstance . changeVanityURL ( 'noassigned' , { from :accounts [ 5 ] } ) . then ( function ( instance ) {
183
183
assert . isUndefined ( instance , "should error on change vanityURL when not assigned" )
184
184
} ) . catch ( function ( error ) {
185
185
assert . isDefined ( error , "should error on change vanityURL when not assigned" )
186
186
} )
187
187
} ) ;
188
188
189
+ it ( "should error on change vanityURL when vanity is in use" , function ( ) {
190
+ return vanityInstance . changeVanityURL ( 'vinay035' , { from :accounts [ 3 ] } ) . then ( function ( instance ) {
191
+ assert . isUndefined ( instance , "should error on change vanityURL when not assigned" )
192
+ } ) . catch ( function ( error ) {
193
+ assert . isDefined ( error , "should error on change vanityURL when not assigned" )
194
+ } )
195
+ } ) ;
196
+
189
197
it ( "should be able to change vanityURL" , function ( ) {
190
198
return vanityInstance . changeVanityURL ( 'vinay0351' , { from :accounts [ 3 ] } ) . then ( function ( instance ) {
191
199
assert . isDefined ( instance , "should be able to change vanityURL" )
You can’t perform that action at this time.
0 commit comments