Skip to content

Commit 87b2497

Browse files
authored
Merge pull request #7 from acunap/update-dotnet-sdk
Update .NET SDK to a LTS version
2 parents a595db9 + f34bf6c commit 87b2497

File tree

5 files changed

+18
-20
lines changed

5 files changed

+18
-20
lines changed

.github/workflows/workflow.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@ jobs:
66
build:
77
runs-on: ubuntu-latest
88
steps:
9-
- uses: actions/checkout@v1
9+
- uses: actions/checkout@v2
1010
- name: Setup .NET Core
1111
uses: actions/setup-dotnet@v1
1212
with:
13-
dotnet-version: 3.1.404
13+
dotnet-version: 6.0.x
1414
- name: Build with dotnet
1515
run: dotnet build --configuration Release
1616
- name: Unit Tests

src/CsharpBasicSkeleton/CsharpBasicSkeleton.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<RootNamespace>CodelyTv.CsharpBasicSkeleton</RootNamespace>
66
<AssemblyName>CodelyTv.CsharpBasicSkeleton</AssemblyName>
77
</PropertyGroup>

src/CsharpBasicSkeleton/Greeter.cs

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
1-
namespace CodelyTv.CsharpBasicSkeleton
1+
namespace CodelyTv.CsharpBasicSkeleton;
2+
3+
public static class Greeter
24
{
3-
public static class Greeter
5+
public static string Greet(string name)
46
{
5-
public static string Greet(string name)
6-
{
7-
return $"Hello {name}";
8-
}
7+
return $"Hello {name}";
98
}
10-
}
9+
}

test/CsharpBasicSkeleton.Tests/CsharpBasicSkeleton.Tests.csproj

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22

33
<PropertyGroup>
4-
<TargetFramework>netcoreapp3.1</TargetFramework>
4+
<TargetFramework>net6.0</TargetFramework>
55
<RootNamespace>CodelyTv.CsharpBasicSkeleton.Tests</RootNamespace>
66

77
<IsPackable>false</IsPackable>
@@ -12,7 +12,7 @@
1212
</PropertyGroup>
1313

1414
<ItemGroup>
15-
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="16.8.0" />
15+
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.0.0" />
1616
<PackageReference Include="xunit" Version="2.4.1" />
1717
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3">
1818
<PrivateAssets>all</PrivateAssets>
Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
11
using Xunit;
22

3-
namespace CodelyTv.CsharpBasicSkeleton.Tests
3+
namespace CodelyTv.CsharpBasicSkeleton.Tests;
4+
5+
public class GreeterShould
46
{
5-
public class GreeterShould
7+
[Fact]
8+
public void Greet_HelloMessage_Receives()
69
{
7-
[Fact]
8-
public void Greet_HelloMessage_Receives()
9-
{
10-
Assert.Equal("Hello Jhon", Greeter.Greet("Jhon"));
11-
}
10+
Assert.Equal("Hello Jhon", Greeter.Greet("Jhon"));
1211
}
13-
}
12+
}

0 commit comments

Comments
 (0)