77 classDeclaration ,
88 classProperty ,
99 promiseTypeAnnotation ,
10- typedIdentifier
10+ typedIdentifier ,
1111} from '../../src/utils/babel' ;
1212import { expectCode } from '../../test-utils' ;
1313
@@ -54,12 +54,12 @@ it('interfaces', async () => {
5454 'limit' ,
5555 t . tsTypeAnnotation ( t . tsStringKeyword ( ) ) ,
5656 true
57- )
57+ ) ,
5858 ] ,
5959 promiseTypeAnnotation ( 'TokensResponse' )
6060 )
6161 )
62- )
62+ ) ,
6363 ] )
6464 )
6565 ) ,
@@ -73,7 +73,7 @@ it('interfaces', async () => {
7373 [
7474 t . tSExpressionWithTypeArguments (
7575 t . identifier ( 'SG721ReadOnlyInstance' )
76- )
76+ ) ,
7777 ] ,
7878 t . tSInterfaceBody ( [
7979 // contract address
@@ -101,15 +101,15 @@ it('interfaces', async () => {
101101 typedIdentifier (
102102 'prop3' ,
103103 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
104- )
104+ ) ,
105105 ] ,
106106 promiseTypeAnnotation ( 'ExecuteResult' )
107107 )
108108 )
109- )
109+ ) ,
110110 ] )
111111 )
112- )
112+ ) ,
113113 ] )
114114 ) ;
115115} ) ;
@@ -149,7 +149,7 @@ it('readonly classes', async () => {
149149 typedIdentifier (
150150 'contractAddress' ,
151151 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
152- )
152+ ) ,
153153 ] ,
154154 t . blockStatement ( [
155155 // client/contract set
@@ -178,7 +178,7 @@ it('readonly classes', async () => {
178178 bindMethod ( 'approval' ) ,
179179 bindMethod ( 'otherProp' ) ,
180180 bindMethod ( 'hello' ) ,
181- bindMethod ( 'mintme' )
181+ bindMethod ( 'mintme' ) ,
182182 ] )
183183 ) ,
184184
@@ -196,7 +196,7 @@ it('readonly classes', async () => {
196196 typedIdentifier (
197197 'spender' ,
198198 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
199- )
199+ ) ,
200200 ] ,
201201 t . blockStatement ( [
202202 t . returnStatement (
@@ -227,31 +227,31 @@ it('readonly classes', async () => {
227227 t . identifier ( 'spender' ) ,
228228 false ,
229229 true
230- )
231- ] )
230+ ) ,
231+ ] ) ,
232232 ]
233233 )
234- )
234+ ) ,
235235 ] ) ,
236236 t . tsTypeAnnotation (
237237 t . tsTypeReference (
238238 t . identifier ( 'Promise' ) ,
239239 t . tsTypeParameterInstantiation ( [
240- t . tSTypeReference ( t . identifier ( 'ApprovalResponse' ) )
240+ t . tSTypeReference ( t . identifier ( 'ApprovalResponse' ) ) ,
241241 ] )
242242 )
243243 ) ,
244244 true
245245 )
246- )
246+ ) ,
247247 ] ,
248248 [
249249 t . tSExpressionWithTypeArguments (
250250 t . identifier ( 'SG721ReadOnlyInstance' )
251- )
251+ ) ,
252252 ]
253253 )
254- )
254+ ) ,
255255 ] )
256256 ) ;
257257} ) ;
@@ -291,14 +291,14 @@ it('mutation classes', async () => {
291291 typedIdentifier (
292292 'contractAddress' ,
293293 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
294- )
294+ ) ,
295295 ] ,
296296 t . blockStatement ( [
297297 // super()
298298 t . expressionStatement (
299299 t . callExpression ( t . super ( ) , [
300300 t . identifier ( 'client' ) ,
301- t . identifier ( 'contractAddress' )
301+ t . identifier ( 'contractAddress' ) ,
302302 ] )
303303 ) ,
304304
@@ -328,7 +328,7 @@ it('mutation classes', async () => {
328328 bindMethod ( 'approval' ) ,
329329 bindMethod ( 'otherProp' ) ,
330330 bindMethod ( 'hello' ) ,
331- bindMethod ( 'mintme' )
331+ bindMethod ( 'mintme' ) ,
332332 ] )
333333 ) ,
334334
@@ -353,7 +353,7 @@ it('mutation classes', async () => {
353353 typedIdentifier (
354354 'token_uri' ,
355355 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
356- )
356+ ) ,
357357 ] ,
358358 t . blockStatement ( [
359359 t . returnStatement (
@@ -391,37 +391,37 @@ it('mutation classes', async () => {
391391 t . objectProperty (
392392 t . identifier ( 'expression' ) ,
393393 t . objectExpression ( [ ] )
394- )
394+ ) ,
395395 ] )
396- )
396+ ) ,
397397 ] ) ,
398- t . stringLiteral ( 'auto' )
398+ t . stringLiteral ( 'auto' ) ,
399399 ]
400400 )
401401 )
402- )
402+ ) ,
403403 ] ) ,
404404 // return type
405405 t . tsTypeAnnotation (
406406 t . tsTypeReference (
407407 t . identifier ( 'Promise' ) ,
408408 t . tsTypeParameterInstantiation ( [
409- t . tSTypeReference ( t . identifier ( 'ExecuteResult' ) )
409+ t . tSTypeReference ( t . identifier ( 'ExecuteResult' ) ) ,
410410 ] )
411411 )
412412 ) ,
413413 true
414414 )
415- )
415+ ) ,
416416 ] ,
417417 [
418418 t . tSExpressionWithTypeArguments (
419419 t . identifier ( 'SG721ReadOnlyInstance' )
420- )
420+ ) ,
421421 ] ,
422422 t . identifier ( 'SG721QueryClient' )
423423 )
424- )
424+ ) ,
425425 ] )
426426 ) ;
427427} ) ;
@@ -439,7 +439,7 @@ it('object parms', () => {
439439 t . identifier ( 'tokenId' ) ,
440440 false ,
441441 true
442- )
442+ ) ,
443443 ] ) ;
444444 obj . typeAnnotation = t . tsTypeAnnotation (
445445 t . tsTypeLiteral ( [
@@ -450,7 +450,7 @@ it('object parms', () => {
450450 t . tsPropertySignature (
451451 t . identifier ( 'tokenId' ) ,
452452 t . tsTypeAnnotation ( t . tsStringKeyword ( ) )
453- )
453+ ) ,
454454 ] )
455455 ) ;
456456 expectCode (
@@ -471,13 +471,13 @@ it('object parms', () => {
471471 t . tsTypeReference (
472472 t . identifier ( 'Promise' ) ,
473473 t . tsTypeParameterInstantiation ( [
474- t . tsTypeReference ( t . identifier ( 'OwnerOfResponse' ) )
474+ t . tsTypeReference ( t . identifier ( 'OwnerOfResponse' ) ) ,
475475 ] )
476476 )
477477 )
478478 )
479479 )
480- )
480+ ) ,
481481 ] )
482482 ) ;
483483} ) ;
0 commit comments