buildframework/helium/sf/java/antlint/tests/data/sample.ant.xml
changeset 645 b8d81fa19e7d
parent 628 7c4a911dc066
equal deleted inserted replaced
643:27cf35f95864 645:b8d81fa19e7d
    25         Testing for tab character
    25         Testing for tab character
    26     </description>
    26     </description>
    27     
    27     
    28     <taskdef resource="net/sf/antcontrib/antlib.xml"/>
    28     <taskdef resource="net/sf/antcontrib/antlib.xml"/>
    29     
    29     
    30         
    30     <var name="var1" value="bar" unset="true"/>
       
    31     <var name="var2" value="bar"  />
       
    32     <var name="var3" unset="true" /> 
       
    33     
    31     <macrodef name="pow" uri="http://www.nokia.com/helium">
    34     <macrodef name="pow" uri="http://www.nokia.com/helium">
    32         <sequential>
    35         <sequential>
    33             <echo>pow</echo>
    36             <echo>pow</echo>
    34         </sequential>
    37         </sequential>
    35     </macrodef>
    38     </macrodef>
    70         <antcall target="hello"/>
    73         <antcall target="hello"/>
    71     </target>
    74     </target>
    72     
    75     
    73     <target name="check-script-size">
    76     <target name="check-script-size">
    74         <hlm:python>
    77         <hlm:python>
    75 print check-script-size
    78 print 'check-script-size'
    76 print check-script-size
    79 print 'check-script-size'
    77 print check-script-size
    80 print 'check-script-size'
    78 print check-script-size
    81 print 'check-script-size'
    79 print check-script-size
    82 print 'check-script-size'
    80 print check-script-size
    83 print 'check-script-size'
    81 print check-script-size
    84 print 'check-script-size'
    82 print check-script-size
    85 print 'check-script-size'
    83 print check-script-size
    86 print 'check-script-size'
    84 print check-script-size
    87 print 'check-script-size'
    85 print check-script-size
    88 print 'check-script-size'
    86 print check-script-size
    89 print 'check-script-size'
    87 print check-script-size
    90 print 'check-script-size'
    88 print check-script-size
    91 print 'check-script-size'
    89 print check-script-size
    92 print 'check-script-size'
    90 print check-script-size
    93 print 'check-script-size'
    91 print check-script-size
    94 print 'check-script-size'
    92 print check-script-size
    95 print 'check-script-size'
    93 print check-script-size
    96 print 'check-script-size'
    94 print check-script-size
    97 print 'check-script-size'
    95 print check-script-size
    98 print 'check-script-size'
    96 print check-script-size
    99 print 'check-script-size'
    97 print check-script-size
   100 print 'check-script-size'
    98 print check-script-size
   101 print 'check-script-size'
    99 print check-script-size
   102 print 'check-script-size'
   100 print check-script-size
   103 print 'check-script-size'
   101 print check-script-size
   104 print 'check-script-size'
   102 print check-script-size
   105 print 'check-script-size'
   103 print check-script-size
   106 print 'check-script-size'
   104 print check-script-size
   107 print 'check-script-size'
   105 print check-script-size
   108 print 'check-script-size'
   106 print check-script-size
   109 print 'check-script-size'
   107 print check-script-size
   110 print 'check-script-size'
   108 print check-script-size
   111 print 'check-script-size'
   109 print check-script-size
   112 print 'check-script-size'
   110 print check-script-size
   113 print 'check-script-size'
   111 print check-script-size
   114 print 'check-script-size'
   112 print check-script-size
   115 print 'check-script-size'
   113 print check-script-size
   116 print 'check-script-size'
   114 print check-script-size
   117 print 'check-script-size'
   115 print check-script-size
   118 print 'check-script-size'
   116 print check-script-size
   119 print 'check-script-size'
   117 print check-script-size         
   120 print 'check-script-size'         
   118 print check-script-size
   121 print 'check-script-size'
   119 print check-script-size
   122 print 'check-script-size'
   120         </hlm:python>
   123         </hlm:python>
   121     </target>
   124     </target>
   122     
   125     
   123     <target name="check-use-of-if-in-targets">
   126     <target name="check-use-of-if-in-targets">
   124         <if>
   127         <if>
   185     </target>
   188     </target>
   186 
   189 
   187     <target name="check-prop-in-pythontask">    
   190     <target name="check-prop-in-pythontask">    
   188         <hlm:python>
   191         <hlm:python>
   189 from path import path
   192 from path import path
       
   193 print abcd
   190 print "Writing version file...."
   194 print "Writing version file...."
   191 vfile = path(r'${build.drive}'+"/").joinpath('s60_version.txt')
   195 vfile = path(r'${build.drive}'+"/").joinpath('s60_version.txt')
   192 f = open(str(vfile), 'w')
   196 f = open(str(vfile), 'w')
   193 f.write(path(r'${s60.getenv.path}').name)
   197 f.write(path(r'${s60.getenv.path}').name)
   194 f.close()
   198 f.close()
   292             <catch>
   296             <catch>
   293                 <echo> inside catch2 </echo>
   297                 <echo> inside catch2 </echo>
   294             </catch>
   298             </catch>
   295         </trycatch>
   299         </trycatch>
   296     </target> 
   300     </target> 
       
   301 
       
   302     <!-- Test property to check for invalid string property types.
       
   303     @type string
       
   304     @scope public
       
   305     -->
       
   306     <property name="test.prop.str.1" value="str.prop"/>
       
   307     
       
   308     <!-- Test property to check for invalid string property types.
       
   309     @type string
       
   310     @scope private
       
   311     -->
       
   312     <property name="test.prop.str.2" value="12345"/>
       
   313 
       
   314     <!-- Test property to check for invalid integer property types.
       
   315     @type integer
       
   316     @scope public
       
   317     -->
       
   318     <property name="test.prop.int.1" value="123"/>
       
   319 
       
   320     <!-- Test property to check for invalid integer property types.
       
   321     @type integer
       
   322     @scope public
       
   323     -->
       
   324     <property name="test.prop.int.2" value="123abc"/>
   297      
   325      
       
   326     <!-- Test property to check for invalid boolean property types.
       
   327     @type boolean
       
   328     @scope public
       
   329     -->
       
   330     <property name="test.prop.bool.1" value="true"/>
       
   331     
       
   332     <!-- Test property to check for invalid boolean property types.
       
   333     @type boolean
       
   334     @scope public
       
   335     -->
       
   336     <property name="test.prop.bool.2" value="false"/>
       
   337     
       
   338     <!-- Test property to check for invalid boolean property types.
       
   339     @type boolean
       
   340     @scope public
       
   341     -->
       
   342     <property name="test.prop.bool.3" value="t"/>
       
   343     
       
   344     <!-- Test property to check for invalid boolean property types.
       
   345     @type boolean
       
   346     @scope public
       
   347     -->
       
   348     <property name="test.prop.bool.4" value="f"/>
       
   349     
       
   350     <!-- Test property to check for invalid boolean property types.
       
   351     @type boolean
       
   352     @scope public
       
   353     -->
       
   354     <property name="test.prop.bool.5" value="yes"/>
       
   355 
       
   356     <!-- Test property to check for invalid boolean property types.
       
   357     @type boolean
       
   358     @scope public
       
   359     -->
       
   360     <property name="test.prop.bool.6" value="no"/>
       
   361 
       
   362     <!-- Test property to check for invalid boolean property types.
       
   363     @type boolean
       
   364     @scope public
       
   365     -->
       
   366     <property name="test.prop.bool.7" value="poo"/>
       
   367 
       
   368    <!--* @property test.comment.str.prop
       
   369    Test comment property to check for invalid string values.   
       
   370    @type string
       
   371    @scope public
       
   372    @since 10.0
       
   373    -->
       
   374 
       
   375    <!--* @property test.comment.int.prop
       
   376    Test comment property to check for invalid integer values.   
       
   377    @type integer
       
   378    @scope public
       
   379    @since 10.0
       
   380    -->
       
   381 
       
   382    <!--* @property test.comment.bool.prop
       
   383    Test comment property to check for invalid string values.   
       
   384    @type boolean
       
   385    @scope public
       
   386    @since 10.0
       
   387    -->
       
   388 
       
   389    <!-- Test property to check for invalid integer property types.
       
   390    @type number
       
   391    @scope public
       
   392    -->
       
   393    <property name="test.prop.number.1" value="1234"/>
       
   394      
       
   395    <!-- Test property to check for invalid boolean property types.
       
   396    @type flag
       
   397    @scope public
       
   398    -->
       
   399    <property name="test.prop.flag" value="true"/>
       
   400 
       
   401    <!-- Test property to check for valid float property types.
       
   402    @type float
       
   403    @scope public
       
   404    -->
       
   405    <property name="test.prop.float.1" value="1.5"/>
       
   406 
       
   407    <!-- Test property to check for invalid float property types.
       
   408    @type float
       
   409    @scope public
       
   410    -->
       
   411    <property name="test.prop.float.2" value="1.5a"/>
       
   412 
       
   413    <!-- Test property to check for invalid integer property types.
       
   414    @type integer
       
   415    @scope public
       
   416    -->
       
   417    <property name="test.prop.int.3" value="1.8"/>
       
   418 
   298 </project>
   419 </project>