This repository has been archived by the owner on Jul 10, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f79ef68
commit d53c25f
Showing
5 changed files
with
58 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<ItemGroup> | ||
<PackageReference Include="xunit" Version="2.5.3" /> | ||
<PackageReference Include="xunit.abstractions" Version="2.0.3" /> | ||
<PackageReference Include="xunit.assert" Version="2.5.3" /> | ||
<PackageReference Include="xunit.core" Version="2.5.3" /> | ||
<PackageReference Include="xunit.extensibility.core" Version="2.5.3" /> | ||
<PackageReference Include="xunit.extensibility.execution" Version="2.5.3" /> | ||
<PackageReference Include="xunit.runner.console" Version="2.5.3" /> | ||
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.3" /> | ||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.2.0" /> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
tests/OneWare.Essentials.UnitTests/OneWare.Essentials.UnitTests.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<Import Project="..\..\build\props\XUnit.props" /> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<OutputType>Library</OutputType> | ||
<IsPackable>False</IsPackable> | ||
<IsTestProject>True</IsTestProject> | ||
<GenerateAssemblyInfo>False</GenerateAssemblyInfo> | ||
<GenerateRuntimeConfigurationFiles>True</GenerateRuntimeConfigurationFiles> | ||
<Nullable>enable</Nullable> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\..\src\OneWare.Essentials\OneWare.Essentials.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
using OneWare.Essentials.Helpers; | ||
using Xunit; | ||
|
||
namespace OneWare.Essentials.UnitTests; | ||
|
||
public class ProjectHelperTests | ||
{ | ||
[Fact] | ||
public void MathWildCardTests() | ||
{ | ||
var include = new[] {"**"}; | ||
var exclude = new[] {".git"}; | ||
|
||
Assert.False(ProjectHelper.MatchWildCards(".git/FETCH_HEAD", include, exclude)); | ||
Assert.True(ProjectHelper.MatchWildCards("test.vhd", include, exclude)); | ||
Assert.True(ProjectHelper.MatchWildCards("nice/test.vhd", include, exclude)); | ||
} | ||
} |