Skip to content

Commit

Permalink
Merge pull request #7 from jjm-one/develop
Browse files Browse the repository at this point in the history
adds strong naming
  • Loading branch information
jonas-merkle authored Jun 7, 2023
2 parents f25c0be + 73c62b3 commit 3c29ada
Show file tree
Hide file tree
Showing 8 changed files with 107 additions and 29 deletions.
26 changes: 26 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"version": "0.2.0",
"configurations": [
{
// Use IntelliSense to find out which attributes exist for C# debugging
// Use hover for the description of the existing attributes
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
"name": ".NET Core Launch (console)",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
// If you have changed target frameworks, make sure to update the program path.
"program": "${workspaceFolder}/src/jjm.one.MiscUtilClasses.Tests/bin/Debug/net7.0/jjm.one.MiscUtilClasses.Tests.dll",
"args": [],
"cwd": "${workspaceFolder}/src/jjm.one.MiscUtilClasses.Tests",
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
"console": "internalConsole",
"stopAtEntry": false
},
{
"name": ".NET Core Attach",
"type": "coreclr",
"request": "attach"
}
]
}
41 changes: 41 additions & 0 deletions .vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/src/jjm.one.MiscUtilClasses.Tests/jjm.one.MiscUtilClasses.Tests.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "publish",
"command": "dotnet",
"type": "process",
"args": [
"publish",
"${workspaceFolder}/src/jjm.one.MiscUtilClasses.Tests/jjm.one.MiscUtilClasses.Tests.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "watch",
"command": "dotnet",
"type": "process",
"args": [
"watch",
"run",
"--project",
"${workspaceFolder}/src/jjm.one.MiscUtilClasses.Tests/jjm.one.MiscUtilClasses.Tests.csproj"
],
"problemMatcher": "$msCompile"
}
]
}
54 changes: 29 additions & 25 deletions src/jjm.one.MiscUtilClasses.Tests/Types/basic/AppInfoTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,17 @@ namespace jjm.one.MiscUtilClasses.Tests.Types.basic
/// </summary>
public class AppInfoTests
{
#region Test "ctor"
#region tests

#region Test "ctor"

/// <summary>
/// 1. test of the default ctos.
/// 1. test of the default constructor.
/// </summary>
[Fact]
public void CtorTest1()
{
var appInfo = new AppInfo();
[Fact]
public void CtorTest1()
{
var appInfo = new AppInfo();

Assert.Equal("unknown", appInfo.AppName);
Assert.Equal("unknown", appInfo.AppVersion);
Expand All @@ -25,7 +27,7 @@ public void CtorTest1()
}

/// <summary>
/// 2. test of the default ctor.
/// 2. test of the default constructor.
/// </summary>
[Fact]
public void CtorTest2()
Expand All @@ -47,7 +49,7 @@ public void CtorTest2()
}

/// <summary>
/// 1. test of the additional ctor.
/// 1. test of the additional constructor.
/// </summary>
[Fact]
public void CtorTest3()
Expand All @@ -68,7 +70,7 @@ public void CtorTest3()
}

/// <summary>
/// 2. test of the additional ctor.
/// 2. test of the additional constructor.
/// </summary>
[Fact]
public void CtorTest4()
Expand Down Expand Up @@ -96,31 +98,33 @@ public void CtorTest4()
/// 1. test of the "ToString()" method.
/// </summary>
[Fact]
public void ToStringTest1()
{
var appInfo = new AppInfo();
public void ToStringTest1()
{
var appInfo = new AppInfo();

Assert.Equal("unknown [Version: unknown - unknown @ unknown | Env: unknown]", appInfo.ToString());
}
Assert.Equal("unknown [Version: unknown - unknown @ unknown | Env: unknown]", appInfo.ToString());
}

/// <summary>
/// 2. test of the "ToString()" method.
/// </summary>
/// <summary>
/// 2. test of the "ToString()" method.
/// </summary>
[Fact]
public void ToStringTest2()
{
var appInfo = new AppInfo
{
AppName = "A",
AppVersion = "B",
AppBuildDate = "C",
AppBuildTime = "D",
AppRuntimeEnvironment = "E"
};
var appInfo = new AppInfo
{
AppName = "A",
AppVersion = "B",
AppBuildDate = "C",
AppBuildTime = "D",
AppRuntimeEnvironment = "E"
};

Assert.Equal("A [Version: B - C @ D | Env: E]", appInfo.ToString());
}

#endregion

#endregion
}
}
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,14 @@
<RootNamespace>jjm.one.MiscUtilClasses.Tests</RootNamespace>
<Title>jjm.one.MiscUtilClasses.Tests</Title>
<Description>A collection of miscellaneous utility and helper classes for C# projects. (Unit-Tests)</Description>
<PackageTags>utility, helper, classes, csharp, tests</PackageTags>
<PackageProjectUrl>https://github.com/jjm-one/jjm.one.MiscUtilClasses</PackageProjectUrl>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/jjm-one/jjm.one.MiscUtilClasses.git</RepositoryUrl>
<IsPackable>false</IsPackable>
<IsTestProject>true</IsTestProject>
<SignAssembly>True</SignAssembly>
<AssemblyOriginatorKeyFile>jjm.one.MiscUtilClasses.Tests.SignKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.
4 changes: 4 additions & 0 deletions src/jjm.one.MiscUtilClasses/jjm.one.MiscUtilClasses.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -7,16 +7,20 @@
<Version>1.0.0-alpha.2</Version>
<Authors>Jonas Merkle [JJM] </Authors>
<Copyright>© by Jonas Merkle [JJM], 2023.</Copyright>
<RootNamespace>jjm.one.MiscUtilClasses</RootNamespace>
<PackageId>jjm.one.MiscUtilClasses</PackageId>
<Title>jjm.one.MiscUtilClasses</Title>
<Description>A collection of miscellaneous utility and helper classes for C# projects.</Description>
<PackageTags>utility, helper, classes, csharp</PackageTags>
<PackageProjectUrl>https://github.com/jjm-one/jjm.one.MiscUtilClasses</PackageProjectUrl>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https://github.com/jjm-one/jjm.one.MiscUtilClasses.git</RepositoryUrl>
<PackageReadmeFile>README.md</PackageReadmeFile>
<PackageLicenseFile>LICENSE</PackageLicenseFile>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<SignAssembly>True</SignAssembly>
<AssemblyOriginatorKeyFile>jjm.one.MiscUtilClasses.SignKey.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>

<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
Expand Down

0 comments on commit 3c29ada

Please sign in to comment.