Skip to content

Commit 8fb2c01

Browse files
authored
Merge pull request #316 from Umplify/copilot/fix-315
Fix NuGet package versioning for release pipeline v9.2.0
2 parents 1feb60b + 4e4825f commit 8fb2c01

File tree

4 files changed

+34
-35
lines changed

4 files changed

+34
-35
lines changed

azure-pipelines.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -43,14 +43,14 @@ steps:
4343
arguments: '--configuration $(BuildConfiguration)'
4444

4545
# Pack (with symbols & SourceLink) happens before publish to ensure packages are available as build artifacts
46-
- script: echo Packing library with symbols and SourceLink metadata
46+
- script: echo Packing library with symbols and SourceLink metadata - Version $(Major).$(Minor).$(Revision)
4747
displayName: 'Pre-Pack Info'
4848
- task: DotNetCoreCLI@2
4949
displayName: 'Packing (nupkg + snupkg)'
5050
inputs:
5151
command: 'pack'
5252
packagesToPack: '**/Xunit.Microsoft.DependencyInjection.csproj'
53-
arguments: '--configuration $(BuildConfiguration) /p:ContinuousIntegrationBuild=true /p:IncludeSymbols=true /p:SymbolPackageFormat=snupkg --output $(Build.ArtifactStagingDirectory)/packages'
53+
arguments: '--configuration $(BuildConfiguration) /p:ContinuousIntegrationBuild=true /p:IncludeSymbols=true /p:SymbolPackageFormat=snupkg /p:PackageVersion=$(Major).$(Minor).$(Revision) --output $(Build.ArtifactStagingDirectory)/packages'
5454
nobuild: true
5555
- task: DotNetCoreCLI@2
5656
displayName: 'Running tests in example folder'

src/Abstracts/TestBedFactoryFixture.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ private object CreateInstance(Type testType, IServiceProvider serviceProvider, I
110110
// Use the fixture's existing GetKeyedService method instead of reflection
111111
try
112112
{
113-
var getKeyedServiceMethod = GetType().BaseType?.GetMethod("GetKeyedService",[typeof(string), typeof(ITestOutputHelper)])?.MakeGenericMethod(parameter.ParameterType);
113+
var getKeyedServiceMethod = GetType().BaseType?.GetMethod("GetKeyedService", [typeof(string), typeof(ITestOutputHelper)])?.MakeGenericMethod(parameter.ParameterType);
114114
arg = getKeyedServiceMethod?.Invoke(this, [key, testOutputHelper]);
115115
}
116116
catch

src/Xunit.Microsoft.DependencyInjection.csproj

Lines changed: 31 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,37 @@
44
<LangVersion>latest</LangVersion>
55
<Nullable>enable</Nullable>
66
<ImplicitUsings>enable</ImplicitUsings>
7-
<PackageReadmeFile>README.md</PackageReadmeFile>
8-
<!-- Enable XML documentation output for NuGet consumers -->
9-
<GenerateDocumentationFile>true</GenerateDocumentationFile>
10-
<!-- Enforce completeness: do NOT suppress CS1591 (removed) -->
11-
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\Xunit.Microsoft.DependencyInjection.xml</DocumentationFile>
12-
<!-- Repository / SourceLink metadata -->
13-
<RepositoryUrl>https://github.com/Umplify/xunit-dependency-injection</RepositoryUrl>
14-
<RepositoryType>git</RepositoryType>
15-
<PublishRepositoryUrl>true</PublishRepositoryUrl>
16-
<EmbedUntrackedSources>true</EmbedUntrackedSources>
17-
<IncludeSymbols>true</IncludeSymbols>
18-
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
19-
<EnableSourceLink>true</EnableSourceLink>
20-
<!-- Optional: mark builds as CI to embed commit information when built on CI -->
21-
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
7+
8+
<!-- NuGet Package Properties -->
9+
<PackageId>Xunit.Microsoft.DependencyInjection</PackageId>
10+
<Title>Microsoft Dependency Injection utility for Xunit</Title>
11+
<Authors>Arash Sabet</Authors>
12+
<Company>Umplify Technologies Inc.</Company>
13+
<Product>Xunit.Microsoft.DependencyInjection</Product>
14+
<Description>This package contains the necessary classes and features to leverage Xunit's fixture class for Microsoft dependency injection framework.</Description>
15+
<Copyright>2025 - All rights reserved, Umplify Technologies Inc.</Copyright>
16+
<PackageTags>xunit;dependency-injection;microsoft-dependency-injection;xunit-dependency-injection</PackageTags>
17+
<PackageProjectUrl>https://umplify.github.io/xunit-dependency-injection/</PackageProjectUrl>
18+
<PackageLicenseExpression>MIT</PackageLicenseExpression>
19+
<PackageRequireLicenseAcceptance>true</PackageRequireLicenseAcceptance>
20+
<PackageReadmeFile>README.md</PackageReadmeFile>
21+
22+
<!-- Enable XML documentation output for NuGet consumers -->
23+
<GenerateDocumentationFile>true</GenerateDocumentationFile>
24+
<!-- Enforce completeness: do NOT suppress CS1591 (removed) -->
25+
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\Xunit.Microsoft.DependencyInjection.xml</DocumentationFile>
26+
27+
<!-- Repository / SourceLink metadata -->
28+
<RepositoryUrl>https://github.com/Umplify/xunit-dependency-injection</RepositoryUrl>
29+
<RepositoryType>git</RepositoryType>
30+
<PublishRepositoryUrl>true</PublishRepositoryUrl>
31+
<EmbedUntrackedSources>true</EmbedUntrackedSources>
32+
<IncludeSymbols>true</IncludeSymbols>
33+
<SymbolPackageFormat>snupkg</SymbolPackageFormat>
34+
<EnableSourceLink>true</EnableSourceLink>
35+
36+
<!-- Optional: mark builds as CI to embed commit information when built on CI -->
37+
<ContinuousIntegrationBuild>true</ContinuousIntegrationBuild>
2238
</PropertyGroup>
2339
<ItemGroup>
2440
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="9.0.8" />

src/package.nuspec

Lines changed: 0 additions & 17 deletions
This file was deleted.

0 commit comments

Comments
 (0)