Welcome to mirror list, hosted at ThFree Co, Russian Federation.

corefx-tests-restore.proj « netcore - github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 1cd7b8f207a47d3112aa1f4ee38af80ae2198034 (plain)
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
34
35
36
37
38
39
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">

    <Target Name="DownloadTest">
        <DownloadFile
            SourceUrl="$(FEED_BASE_URL)/$(TestFile)"
            DestinationFolder="$(MSBuildProjectDirectory)/corefx/tests"
            Retries="3">
            <Output TaskParameter="DownloadedFile" ItemName="Content" />
        </DownloadFile>
    </Target>

    <Target Name="DownloadTestsList">
        <DownloadFile
            SourceUrl="$(FEED_BASE_URL)/$(TEST_ASSETS_PATH)"
            DestinationFolder="$(MSBuildProjectDirectory)/corefx/tests"
            Retries="3">
            <Output TaskParameter="DownloadedFile" ItemName="Content" />
        </DownloadFile>
        <XmlPeek
            XmlInputPath="$(MSBuildProjectDirectory)/corefx/tests/corefx-test-assets.xml" 
            Query="/Build/Blob/@Id">
            <Output TaskParameter="Result" ItemName="AllTests" />
        </XmlPeek>
    </Target>

    <Target Name="DownloadAllTests" DependsOnTargets="DownloadTestsList">
        <ItemGroup>
            <TempProjects Include="$(MSBuildProjectFile)">
                <Properties>TestFile=%(AllTests.Identity)</Properties>
            </TempProjects>
        </ItemGroup>
        <MSBuild Projects="@(TempProjects)" BuildInParallel="true" StopOnFirstFailure="true" Targets="DownloadTest" />
        <Message Text="Extracting CoreFX tests..." Importance="high" />
        <Unzip
            SourceFiles="$(MSBuildProjectDirectory)/corefx/tests/$([System.IO.Path]::GetFileName('%(AllTests.Identity)'))"
            DestinationFolder="$(MSBuildProjectDirectory)/corefx/tests/extracted/$([System.IO.Path]::GetFileNameWithoutExtension('%(AllTests.Identity)'))" />
    </Target>

</Project>