1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33
|
<?xml version="1.0" encoding="UTF-8"?>
<project name="ChmodTaskTest" default="main">
<property name="tmp.dir" value="tmp"/>
<target name="clean">
<delete dir="${tmp.dir}"/>
</target>
<target name="testChangeModeFile">
<mkdir dir="${tmp.dir}"/>
<touch file="${tmp.dir}/chmodtest"/>
<chmod file="${tmp.dir}/chmodtest" mode="0700"/>
</target>
<target name="testChangeModeFileSet">
<mkdir dir="${tmp.dir}"/>
<touch file="${tmp.dir}/chmodtest"/>
<chmod mode="0700">
<fileset dir="${tmp.dir}">
<include name="chmodtest"/>
</fileset>
</chmod>
</target>
<target name="testChangeModeDirSet">
<mkdir dir="${tmp.dir}/A"/>
<chmod mode="0700">
<dirset dir="${tmp.dir}">
<include name="A"/>
</dirset>
</chmod>
</target>
</project>
|