43 строки
1.9 KiB
XML
43 строки
1.9 KiB
XML
<?xml version="1.0" encoding="UTF-8" ?>
|
|
<project name="test resource prepration and cleanup">
|
|
<target name="setup">
|
|
<echo message="setup test resource"/>
|
|
<exec osfamily="windows" executable="cmd.exe">
|
|
<arg value="/c"/>
|
|
<arg value=".\src\libs\setup.bat"/>
|
|
<arg value="${azure.test.resourcegroup}"/>
|
|
<arg value="${azure.test.dbname}"/>
|
|
<redirector outputproperty="cosmosdb.keys"/>
|
|
</exec>
|
|
<exec osfamily="unix" executable="bash">
|
|
<arg value="./src/libs/setup.sh"/>
|
|
<arg value="${azure.test.resourcegroup}"/>
|
|
<arg value="${azure.test.dbname}"/>
|
|
<redirector outputproperty="cosmosdb.keys"/>
|
|
</exec>
|
|
<script language="javascript">
|
|
project.setProperty('cosmosdb.key', project.getProperty('cosmosdb.keys').split(' ')[0]);
|
|
project.setProperty('cosmosdb.secondaryKey', project.getProperty('cosmosdb.keys').split(' ')[1]);
|
|
</script>
|
|
<propertyfile file="./src/test/resources/application.properties">
|
|
<entry key="cosmosdb.key" value="${cosmosdb.key}"/>
|
|
<entry key="cosmosdb.secondaryKey" value="${cosmosdb.secondaryKey}"/>
|
|
<entry key="cosmosdb.uri" value="https://${azure.test.dbname}.documents.azure.com:443"/>
|
|
</propertyfile>
|
|
</target>
|
|
<target name="cleanup">
|
|
<echo message="cleanup test resource"/>
|
|
<exec osfamily="windows" executable="cmd.exe">
|
|
<arg value="/c"/>
|
|
<arg value=".\src\libs\cleanup.bat"/>
|
|
<arg value="${azure.test.resourcegroup}"/>
|
|
<arg value="${azure.test.dbname}"/>
|
|
</exec>
|
|
<exec osfamily="unix" executable="bash">
|
|
<arg value="./src/libs/cleanup.sh"/>
|
|
<arg value="${azure.test.resourcegroup}"/>
|
|
<arg value="${azure.test.dbname}"/>
|
|
</exec>
|
|
</target>
|
|
</project>
|