Skip to content

Commit a61b643

Browse files
committed
Remove usage of shared embeded files
The StaticGenerator already provides access to the files added by default to the compilation for testing, no need to include them like we did when they were added via contentFiles by nuget.
1 parent a98400b commit a61b643

File tree

4 files changed

+7
-1
lines changed

4 files changed

+7
-1
lines changed

src/DependencyInjection.Tests/ConventionsTests.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,9 @@ public void RegisterGenericServices()
4343
{
4444
var conventions = new ServiceCollection();
4545

46+
#pragma warning disable DDI003
4647
conventions.AddServices(typeof(IGenericRepository<>), ServiceLifetime.Scoped);
48+
#pragma warning restore DDI003
4749

4850
var services = conventions.BuildServiceProvider();
4951

src/DependencyInjection.Tests/DependencyInjection.Tests.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,6 @@
2828
<Using Include="Xunit.Abstractions" />
2929
</ItemGroup>
3030

31-
<Import Project="ContentFiles.targets" />
3231
<Import Project="..\DependencyInjection\Devlooped.Extensions.DependencyInjection.targets" />
3332

3433
</Project>

src/Samples/ConsoleApp/ConsoleApp.csproj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
<!-- Allow inspection of generated code under obj -->
99
<EmitCompilerGeneratedFiles>true</EmitCompilerGeneratedFiles>
1010
<GenerateDocumentationFile>false</GenerateDocumentationFile>
11+
<WarningsAsErrors>true</WarningsAsErrors>
1112
</PropertyGroup>
1213

1314
<ItemGroup>

src/Samples/Library2/Library2.csproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,4 +10,8 @@
1010
<PackageReference Include="Merq" Version="2.0.0" />
1111
</ItemGroup>
1212

13+
<ItemGroup>
14+
<ProjectReference Include="..\Library1\Library1.csproj" />
15+
</ItemGroup>
16+
1317
</Project>

0 commit comments

Comments
 (0)