Skip to content

Commit c2ce011

Browse files
committed
Introduced Directory.Build.props for tests
1 parent 55f606c commit c2ce011

File tree

69 files changed

+35
-195
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+35
-195
lines changed

tests/Directory.Build.props

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<Project xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
3+
<ItemGroup>
4+
<PackageReference Include="bunit" Version="1.4.15" />
5+
<PackageReference Include="FluentAssertions" Version="6.4.0" />
6+
<PackageReference Include="Moq" Version="4.16.1" />
7+
<PackageReference Include="xunit" Version="2.4.2-pre.12" />
8+
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
9+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
10+
<PrivateAssets>all</PrivateAssets>
11+
</PackageReference>
12+
<PackageReference Include="coverlet.collector" Version="3.1.1">
13+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
14+
<PrivateAssets>all</PrivateAssets>
15+
</PackageReference>
16+
<PackageReference Include="coverlet.msbuild" Version="3.1.1">
17+
<PrivateAssets>all</PrivateAssets>
18+
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
19+
</PackageReference>
20+
</ItemGroup>
21+
22+
<ItemGroup Label="Implicit usings">
23+
<Using Include="FluentAssertions" />
24+
<Using Include="Moq" />
25+
<Using Include="Xunit" />
26+
</ItemGroup>
27+
28+
</Project>

tests/LinkDotNet.Blog.IntegrationTests/Infrastructure/Persistence/CachedRepositoryTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,9 @@
11
using System.Linq;
22
using System.Threading.Tasks;
3-
using FluentAssertions;
43
using LinkDotNet.Blog.Domain;
54
using LinkDotNet.Blog.Infrastructure.Persistence;
65
using LinkDotNet.Blog.TestUtilities;
76
using Microsoft.Extensions.Caching.Memory;
8-
using Xunit;
97

108
namespace LinkDotNet.Blog.IntegrationTests.Infrastructure.Persistence;
119

tests/LinkDotNet.Blog.IntegrationTests/Infrastructure/Persistence/RavenDb/BlogPostRepositoryTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
using System.Linq;
22
using System.Threading.Tasks;
3-
using FluentAssertions;
43
using LinkDotNet.Blog.Domain;
54
using LinkDotNet.Blog.Infrastructure.Persistence;
65
using LinkDotNet.Blog.Infrastructure.Persistence.RavenDb;
76
using LinkDotNet.Blog.TestUtilities;
87
using Raven.Client.Documents;
98
using Raven.TestDriver;
10-
using Xunit;
119

1210
namespace LinkDotNet.Blog.IntegrationTests.Infrastructure.Persistence.RavenDb;
1311

tests/LinkDotNet.Blog.IntegrationTests/Infrastructure/Persistence/Sql/BlogPostRepositoryTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,8 @@
11
using System.Linq;
22
using System.Threading.Tasks;
3-
using FluentAssertions;
43
using LinkDotNet.Blog.Domain;
54
using LinkDotNet.Blog.TestUtilities;
65
using Microsoft.EntityFrameworkCore;
7-
using Xunit;
86

97
namespace LinkDotNet.Blog.IntegrationTests.Infrastructure.Persistence.Sql;
108

tests/LinkDotNet.Blog.IntegrationTests/Infrastructure/Persistence/Sql/ProfileRepositoryTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
using System.Threading.Tasks;
2-
using FluentAssertions;
32
using LinkDotNet.Blog.Domain;
43
using LinkDotNet.Blog.TestUtilities;
5-
using Xunit;
64

75
namespace LinkDotNet.Blog.IntegrationTests.Infrastructure.Persistence.Sql;
86

tests/LinkDotNet.Blog.IntegrationTests/Infrastructure/Persistence/Sql/SkillRepositoryTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
using System.Threading.Tasks;
2-
using FluentAssertions;
32
using LinkDotNet.Blog.Domain;
43
using LinkDotNet.Blog.TestUtilities;
5-
using Xunit;
64

75
namespace LinkDotNet.Blog.IntegrationTests.Infrastructure.Persistence.Sql;
86

tests/LinkDotNet.Blog.IntegrationTests/LinkDotNet.Blog.IntegrationTests.csproj

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,9 @@
66
</PropertyGroup>
77

88
<ItemGroup>
9-
<PackageReference Include="bunit" Version="1.4.15" />
10-
<PackageReference Include="FluentAssertions" Version="6.4.0" />
119
<PackageReference Include="Microsoft.AspNetCore.Mvc.Testing" Version="6.0.1" />
1210
<PackageReference Include="Microsoft.EntityFrameworkCore.Sqlite" Version="6.0.1" />
1311
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.1.0-release-20220113-05" />
14-
<PackageReference Include="Moq" Version="4.16.1" />
1512
<PackageReference Include="RavenDB.TestDriver" Version="5.3.100" />
1613
<PackageReference Include="SonarAnalyzer.CSharp" Version="8.35.0.42613">
1714
<PrivateAssets>all</PrivateAssets>
@@ -21,19 +18,6 @@
2118
<PrivateAssets>all</PrivateAssets>
2219
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
2320
</PackageReference>
24-
<PackageReference Include="xunit" Version="2.4.2-pre.12" />
25-
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
26-
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
27-
<PrivateAssets>all</PrivateAssets>
28-
</PackageReference>
29-
<PackageReference Include="coverlet.collector" Version="3.1.1">
30-
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
31-
<PrivateAssets>all</PrivateAssets>
32-
</PackageReference>
33-
<PackageReference Include="coverlet.msbuild" Version="3.1.1">
34-
<PrivateAssets>all</PrivateAssets>
35-
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
36-
</PackageReference>
3721
</ItemGroup>
3822

3923
<ItemGroup>
@@ -49,4 +33,4 @@
4933
<CodeAnalysisRuleSet>..\..\stylecop.analyzers.ruleset</CodeAnalysisRuleSet>
5034
</PropertyGroup>
5135

52-
</Project>
36+
</Project>

tests/LinkDotNet.Blog.IntegrationTests/SmokeTests.cs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,7 @@
11
using System.Threading.Tasks;
2-
using FluentAssertions;
32
using LinkDotNet.Blog.Infrastructure.Persistence;
43
using LinkDotNet.Blog.Web;
54
using Microsoft.AspNetCore.Mvc.Testing;
6-
using Xunit;
75

86
namespace LinkDotNet.Blog.IntegrationTests;
97

tests/LinkDotNet.Blog.IntegrationTests/SqlDatabaseTestBase.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
using LinkDotNet.Blog.Infrastructure.Persistence.Sql;
66
using Microsoft.Data.Sqlite;
77
using Microsoft.EntityFrameworkCore;
8-
using Xunit;
98

109
namespace LinkDotNet.Blog.IntegrationTests;
1110

tests/LinkDotNet.Blog.IntegrationTests/Web/Pages/Admin/CreateNewBlogPostPageTests.cs

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
using Blazored.Toast.Services;
33
using Bunit;
44
using Bunit.TestDoubles;
5-
using FluentAssertions;
65
using LinkDotNet.Blog.Domain;
76
using LinkDotNet.Blog.Infrastructure.Persistence;
87
using LinkDotNet.Blog.Web.Pages.Admin;
@@ -11,8 +10,6 @@
1110
using LinkDotNet.Blog.Web.Shared.Services;
1211
using Microsoft.EntityFrameworkCore;
1312
using Microsoft.Extensions.DependencyInjection;
14-
using Moq;
15-
using Xunit;
1613

1714
namespace LinkDotNet.Blog.IntegrationTests.Web.Pages.Admin;
1815

0 commit comments

Comments
 (0)