Skip to content

Commit d008403

Browse files
WIP
1 parent 88300e1 commit d008403

File tree

5 files changed

+31
-9
lines changed

5 files changed

+31
-9
lines changed

Directory.Build.props

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
<ImplicitUsings>true</ImplicitUsings>
2121
<Nullable>enable</Nullable>
2222
</PropertyGroup>
23+
2324
<PropertyGroup Condition="'$(GITHUB_ACTIONS)' == 'true'">
2425
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
2526
</PropertyGroup>

Directory.Packages.props

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
99
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="8.0.0" />
1010
<PackageVersion Include="Moq" Version="4.20.69" />
11-
<PackageVersion Include="xunit" Version="2.7.1" />
12-
<PackageVersion Include="xunit.runner.visualstudio" Version="2.5.8" />
11+
<PackageVersion Include="xunit" Version="2.8.1" />
12+
<PackageVersion Include="xunit.runner.visualstudio" Version="2.8.1" />
1313
</ItemGroup>
1414
</Project>

IntelliTect.Multitool.Tests/Extensions/HttpExtensionsTests.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ static HttpExtensionsTests()
1515
[InlineData("https://thisisaverybadurlthatwillnotworkhopefullyever.com/", false)]
1616
[InlineData("https://www.google.com/", true)]
1717
[InlineData("https://api.github.com/meta", true)]
18-
public async void ValidateUri_CheckUrl_SuccessIsAsExpected(string urlUnderTest, bool expected)
18+
public async Task ValidateUri_CheckUrl_SuccessIsAsExpected(string urlUnderTest, bool expected)
1919
{
2020
Assert.Equal(expected, await HttpClient.ValidateUri(new Uri(urlUnderTest), new System.Net.Http.Headers.ProductInfoHeaderValue(new System.Net.Http.Headers.ProductHeaderValue("IntelliTect.Multitool.Testing"))));
2121
}

IntelliTect.Multitool.Tests/IntelliTect.Multitool.Tests.csproj

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@
66
<IsPackable>false</IsPackable>
77
</PropertyGroup>
88

9+
<PropertyGroup>
10+
<ReleaseDateAttribute>true></ReleaseDateAttribute>
11+
</PropertyGroup>
12+
913
<ItemGroup>
1014
<PackageReference Include="Moq" />
1115
<PackageReference Include="Microsoft.NET.Test.Sdk" />
@@ -20,4 +24,4 @@
2024
<ItemGroup>
2125
<ProjectReference Include="..\IntelliTect.Multitool\IntelliTect.Multitool.csproj" />
2226
</ItemGroup>
23-
</Project>
27+
</Project>

IntelliTect.Multitool/Build/IntelliTect.Multitool.targets

Lines changed: 22 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,26 @@
11
<Project>
2-
<ItemGroup>
3-
<AssemblyAttribute Include="IntelliTect.Multitool.ReleaseDate">
4-
<_Parameter1>$([System.DateTime]::UtcNow.ToString("O"))</_Parameter1>
5-
</AssemblyAttribute>
6-
</ItemGroup>
2+
<ItemGroup>
3+
<AssemblyAttribute Condition="'$(CI)' == 'true' OR '$(ReleaseDateAttribute)' == 'true'" Include="IntelliTect.Multitool.ReleaseDate">
4+
<_Parameter1>$([System.DateTime]::UtcNow.ToString("O"))</_Parameter1>
5+
</AssemblyAttribute>
6+
</ItemGroup>
7+
8+
<PropertyGroup Label="CI" Condition="'$(CI)' == ''">
9+
<CI>false</CI>
10+
<!-- GH, CircleCI, GitLab and BitBucket already use CI -->
11+
<CI Condition="'$(TF_BUILD)' == 'true' or
12+
'$(TEAMCITY_VERSION)' != '' or
13+
'$(APPVEYOR)' != '' or
14+
'$(BuildRunner)' == 'MyGet' or
15+
'$(JENKINS_URL)' != '' or
16+
'$(TRAVIS)' == 'true' or
17+
'$(BUDDY)' == 'true' or
18+
'$(CODEBUILD_CI)' == 'true'">true</CI>
19+
</PropertyGroup>
20+
21+
<PropertyGroup>
22+
<ReleaseDateAttribute>true</ReleaseDateAttribute>
23+
</PropertyGroup>
724

825
<Target Name="WriteLaunchers" AfterTargets="CopyFilesToOutputDirectory">
926
<PropertyGroup>

0 commit comments

Comments
 (0)