<?xml version="1.0"?>
<project name="to-url" >


  <target name="testEmpty">
    <makeurl/>
  </target>

  <target name="testNoProperty">
    <makeurl file="foo"/>
  </target>

  <target name="testNoFile">
    <makeurl property="foo"/>
  </target>
    
  <target name="testWorks">
    <makeurl property="testWorks" file="foo" validate="false"/>
    <fail unless="testWorks" />
  </target>

  <target name="testIllegalChars">
    <makeurl property="testIllegalChars" file="fo o%" validate="false"/>
  </target>
  
  <target name="testRoundTrip">
    <makeurl property="testRoundTrip" file="${ant.file}"/>
  </target>

  <target name="testIllegalCombinations">
    <makeurl property="testIllegalCombinations" file="foo" validate="false">
      <fileset dir="." includes="*.xml" />
    </makeurl>
  </target>
  
  
  <target name="testFileset">
    <makeurl property="testFileset">
      <fileset dir="." includes="*.xml" />
    </makeurl>
  </target>
  
  <target name="testFilesetSeparator">
    <makeurl property="testFilesetSeparator" separator='","'>
      <fileset dir="." includes="*.xml" />
    </makeurl>
  </target>

  <target name="testValidation">
    <makeurl property="testValidation" file="absent" validate="true"/>
  </target>

  <target name="testPath">
    <path id="test.path">
      <pathelement location="." />
      <fileset dir="." includes="*.xml"/>
    </path>
    <makeurl property="testPath">
      <path refid="test.path" />
    </makeurl>
  </target>

</project>
