initial commit

This commit is contained in:
2019-12-14 16:27:17 +01:00
parent 9572114d62
commit 5f4ac1d3ef
20 changed files with 367 additions and 0 deletions

View File

View File

View File

@@ -0,0 +1,21 @@
using System;
using System.IO;
using System.Linq;
using Microsoft.VisualStudio.TestTools.UnitTesting;
namespace PhotoRenamer.Test
{
[TestClass]
public class FilesTest
{
[TestMethod]
public void FindSupportedFiles()
{
var path = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Assets");
var files = Base.FilesHelper.FindSupportedFilesRecursively(path).ToArray();
Assert.AreEqual(2, files.Length);
Assert.AreEqual("IMG_3590.CR2", Path.GetFileName(files[0]));
Assert.AreEqual("IMG_3590.JPG", Path.GetFileName(files[1]));
}
}
}

View File

@@ -0,0 +1,39 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<IsPackable>false</IsPackable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="Microsoft.CodeAnalysis.FxCopAnalyzers" Version="2.9.8">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.4.0" />
<PackageReference Include="MSTest.TestAdapter" Version="2.0.0" />
<PackageReference Include="MSTest.TestFramework" Version="2.0.0" />
<PackageReference Include="coverlet.collector" Version="1.1.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
</ItemGroup>
<ItemGroup>
<None Update="Assets\IMG_3590.CR2">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Assets\NIX.TXT">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
<None Update="Assets\Subfolder\IMG_3590.JPG">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\PhotoRenamer.Base\PhotoRenamer.Base.csproj" />
</ItemGroup>
</Project>