Skip to content

Commit e06dda7

Browse files
committed
Migrate to *.csproj. Support net4.5
1 parent 4591dbc commit e06dda7

File tree

10 files changed

+80
-73
lines changed

10 files changed

+80
-73
lines changed

Unidecode.NET.sln

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,41 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
3-
# Visual Studio 14
4-
VisualStudioVersion = 14.0.25420.1
3+
# Visual Studio 15
4+
VisualStudioVersion = 15.0.26228.4
55
MinimumVisualStudioVersion = 10.0.40219.1
66
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{604AAA61-6C9C-4421-9DA5-0805968113A8}"
77
EndProject
88
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{C9018F64-4917-4F4F-8F78-3A674896029D}"
99
ProjectSection(SolutionItems) = preProject
10-
global.json = global.json
1110
readme.md = readme.md
1211
EndProjectSection
1312
EndProject
14-
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Unidecode.NET", "src\Unidecode.NET\Unidecode.NET.xproj", "{A1A9B022-442C-4782-AF37-F8E58E5740A3}"
13+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Unidecode.NET", "src\Unidecode.NET.csproj", "{3ED46251-F3F1-43F0-8776-A5055D96BB56}"
14+
EndProject
15+
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "test", "test", "{8F8EB995-97FD-41CD-B307-E2F8E987C468}"
16+
EndProject
17+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Unidecode.NET.Tests", "test\Unidecode.NET.Tests.csproj", "{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B}"
1518
EndProject
1619
Global
1720
GlobalSection(SolutionConfigurationPlatforms) = preSolution
1821
Debug|Any CPU = Debug|Any CPU
1922
Release|Any CPU = Release|Any CPU
2023
EndGlobalSection
2124
GlobalSection(ProjectConfigurationPlatforms) = postSolution
22-
{A1A9B022-442C-4782-AF37-F8E58E5740A3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
23-
{A1A9B022-442C-4782-AF37-F8E58E5740A3}.Debug|Any CPU.Build.0 = Debug|Any CPU
24-
{A1A9B022-442C-4782-AF37-F8E58E5740A3}.Release|Any CPU.ActiveCfg = Release|Any CPU
25-
{A1A9B022-442C-4782-AF37-F8E58E5740A3}.Release|Any CPU.Build.0 = Release|Any CPU
25+
{3ED46251-F3F1-43F0-8776-A5055D96BB56}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
26+
{3ED46251-F3F1-43F0-8776-A5055D96BB56}.Debug|Any CPU.Build.0 = Debug|Any CPU
27+
{3ED46251-F3F1-43F0-8776-A5055D96BB56}.Release|Any CPU.ActiveCfg = Release|Any CPU
28+
{3ED46251-F3F1-43F0-8776-A5055D96BB56}.Release|Any CPU.Build.0 = Release|Any CPU
29+
{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
30+
{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B}.Debug|Any CPU.Build.0 = Debug|Any CPU
31+
{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B}.Release|Any CPU.ActiveCfg = Release|Any CPU
32+
{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B}.Release|Any CPU.Build.0 = Release|Any CPU
2633
EndGlobalSection
2734
GlobalSection(SolutionProperties) = preSolution
2835
HideSolutionNode = FALSE
2936
EndGlobalSection
3037
GlobalSection(NestedProjects) = preSolution
31-
{A1A9B022-442C-4782-AF37-F8E58E5740A3} = {604AAA61-6C9C-4421-9DA5-0805968113A8}
38+
{3ED46251-F3F1-43F0-8776-A5055D96BB56} = {604AAA61-6C9C-4421-9DA5-0805968113A8}
39+
{C93F3F13-BFB7-4440-BC52-B1BFAC74EB1B} = {8F8EB995-97FD-41CD-B307-E2F8E987C468}
3240
EndGlobalSection
3341
EndGlobal

global.json

Lines changed: 0 additions & 6 deletions
This file was deleted.

src/Unidecode.NET.csproj

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
<PropertyGroup>
3+
<TargetFrameworks>net45;netstandard1.3</TargetFrameworks>
4+
<PackageId>Unidecode.NET</PackageId>
5+
<VersionPrefix>1.1.0</VersionPrefix>
6+
<AssemblyName>Unidecode.NET</AssemblyName>
7+
<PackageId>Unidecode.NET</PackageId>
8+
<PackageTags>text;unicode;seo</PackageTags>
9+
<RepositoryType>git</RepositoryType>
10+
<RepositoryUrl>https://github.com/thecoderok/Unidecode.NET</RepositoryUrl>
11+
</PropertyGroup>
12+
13+
<ItemGroup Condition=" '$(TargetFramework)' == 'net45' ">
14+
</ItemGroup>
15+
16+
<PropertyGroup Condition=" '$(TargetFramework)' == 'netstandard1.3' ">
17+
</PropertyGroup>
18+
</Project>

src/Unidecode.NET/Properties/AssemblyInfo.cs

Lines changed: 0 additions & 19 deletions
This file was deleted.

src/Unidecode.NET/Unidecode.NET.xproj

Lines changed: 0 additions & 21 deletions
This file was deleted.

src/Unidecode.NET/project.json

Lines changed: 0 additions & 18 deletions
This file was deleted.
File renamed without changes.

test/Unidecode.NET.Tests.csproj

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<Project Sdk="Microsoft.NET.Sdk">
2+
3+
<PropertyGroup>
4+
<TargetFramework>netcoreapp1.1</TargetFramework>
5+
</PropertyGroup>
6+
7+
<ItemGroup>
8+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="15.0.0" />
9+
<PackageReference Include="xunit" Version="2.2.0" />
10+
<PackageReference Include="xunit.runner.visualstudio" Version="2.2.0" />
11+
</ItemGroup>
12+
13+
<ItemGroup>
14+
<ProjectReference Include="..\src\Unidecode.NET.csproj" />
15+
</ItemGroup>
16+
17+
<ItemGroup>
18+
<Service Include="{82a7f48d-3b50-4b1e-b82e-3ada8210c358}" />
19+
</ItemGroup>
20+
21+
</Project>

test/UnidecoderTest.cs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
using System;
2+
using Xunit;
3+
4+
namespace Unidecode.NET.Tests
5+
{
6+
public class UnidecoderTest
7+
{
8+
[Fact]
9+
public void Test()
10+
{
11+
Assert.Equal("Bei Jing ", "\u5317\u4EB0".Unidecode());
12+
Assert.Equal("Rabota s kirillitsey", "Работа с кириллицей".Unidecode());
13+
Assert.Equal("aouoAOUO", "äöűőÄÖŨŐ".Unidecode());
14+
Assert.Equal("Hello, World!", "Hello, World!".Unidecode());
15+
Assert.Equal("'\"\r\n", "'\"\r\n".Unidecode());
16+
Assert.Equal("CZSczs", "ČŽŠčžš".Unidecode());
17+
Assert.Equal("a", "ア".Unidecode());
18+
Assert.Equal("a", "α".Unidecode());
19+
Assert.Equal("a", "а".Unidecode());
20+
Assert.Equal("chateau", "ch\u00e2teau".Unidecode());
21+
Assert.Equal("vinedos", "vi\u00f1edos".Unidecode());
22+
}
23+
}
24+
}

0 commit comments

Comments
 (0)