File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -90,19 +90,19 @@ describe('wxml-loader', () => {
9090 ) ;
9191 } ) ;
9292
93- test ( 'should formatContent () work' , async ( ) => {
93+ test ( 'should transformContent () work' , async ( ) => {
9494 await compile ( '<view wx:for="{{items}}"> {{item}} </view>' , {
9595 target : function Alipay ( ) { } ,
96- formatContent : ( content ) => content . replace ( / \b w x : / , '🦄:' ) ,
96+ transformContent : ( content ) => content . replace ( / \b w x : / , '🦄:' ) ,
9797 } ) ;
9898 const result = readFile ( ) ;
9999 expect ( result ) . toBe ( '<view 🦄:for="{{items}}"> {{item}} </view>' ) ;
100100 } ) ;
101101
102- test ( 'should formatUrl () work' , async ( ) => {
102+ test ( 'should transformUrl () work' , async ( ) => {
103103 await compile ( '<import src="/fixture.wxml" />' , {
104104 target : function Alipay ( ) { } ,
105- formatUrl : ( url ) => url . replace ( / f i x t u r e / , '🦄' ) ,
105+ transformUrl : ( url ) => url . replace ( / f i x t u r e / , '🦄' ) ,
106106 } ) ;
107107 const result = readFile ( ) ;
108108 expect ( result ) . toBe ( '<import src="/🦄.wxml" />' ) ;
You can’t perform that action at this time.
0 commit comments