Skip to content

Commit

Permalink
Fix code smells
Browse files Browse the repository at this point in the history
  • Loading branch information
olsh committed Nov 10, 2023
1 parent ccc7575 commit 700b2f0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/DotNet.Consolidate.Tests/Services/SolutionParserTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public void Solution_with_DirectoryBuildProps_parsed_correctly_when_not_allowed_

// Assert
Assert.NotNull(solution);
Assert.Equal(0, solution.DirectoryBuildPropsInfos.Count);
Assert.Empty(solution.DirectoryBuildPropsInfos);
}

[Fact]
Expand Down Expand Up @@ -109,22 +109,22 @@ public void Solution_with_DirectoryBuildProps_when_not_allowed_to_read_them_dete

// Assert
Assert.NotNull(projectA);
Assert.Equal(0, projectA.Packages.Count);
Assert.Empty(projectA.Packages);
Assert.Equal(0, projectA.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Direct));
Assert.Equal(0, projectA.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Inherited));

Assert.NotNull(projectB);
Assert.Equal(1, projectB.Packages.Count);
Assert.Single(projectB.Packages);
Assert.Equal(1, projectB.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Direct));
Assert.Equal(0, projectB.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Inherited));

Assert.NotNull(projectATests);
Assert.Equal(0, projectATests.Packages.Count);
Assert.Empty(projectATests.Packages);
Assert.Equal(0, projectATests.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Direct));
Assert.Equal(0, projectATests.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Inherited));

Assert.NotNull(projectBTests);
Assert.Equal(0, projectBTests.Packages.Count);
Assert.Empty(projectBTests.Packages);
Assert.Equal(0, projectBTests.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Direct));
Assert.Equal(0, projectBTests.Packages.Count(p => p.PackageReferenceType == NuGetPackageReferenceType.Inherited));
}
Expand Down

0 comments on commit 700b2f0

Please sign in to comment.