-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge remote-tracking branch 'upstream/dev' into main
- Loading branch information
Showing
29 changed files
with
222 additions
and
145 deletions.
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
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 |
---|---|---|
|
@@ -15,41 +15,41 @@ env: | |
MORYX_OPTIMIZE_CODE: "false" | ||
MORYX_BUILD_CONFIG: "Release" | ||
MORYX_BUILDNUMBER: ${{github.run_number}} | ||
dotnet_sdk_version: '5.0.100' | ||
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true | ||
|
||
jobs: | ||
Build: | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup MSBuild | ||
uses: microsoft/setup-msbuild@v1 | ||
|
||
- name: Setup NuGet.exe | ||
uses: NuGet/[email protected] | ||
|
||
- name: Build | ||
shell: pwsh | ||
run: ./Build.ps1 -Build -Pack | ||
|
||
- name: Upload package artifacts | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: packages | ||
path: artifacts/Packages/ | ||
retention-days: 1 | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{ env.dotnet_sdk_version }} | ||
|
||
- name: Build | ||
shell: pwsh | ||
run: ./Build.ps1 -Build -Pack | ||
|
||
- name: Upload package artifacts | ||
uses: actions/upload-artifact@v2 | ||
with: | ||
name: packages | ||
path: artifacts/Packages/ | ||
retention-days: 1 | ||
|
||
UnitTests: | ||
needs: [Build] | ||
runs-on: windows-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup MSBuild | ||
uses: microsoft/setup-msbuild@v1 | ||
|
||
- name: Setup NuGet.exe | ||
uses: NuGet/[email protected] | ||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{ env.dotnet_sdk_version }} | ||
|
||
- name: Execute Unit Tests | ||
shell: pwsh | ||
|
@@ -68,11 +68,10 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup MSBuild | ||
uses: microsoft/setup-msbuild@v1 | ||
|
||
- name: Setup NuGet.exe | ||
uses: NuGet/[email protected] | ||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{ env.dotnet_sdk_version }} | ||
|
||
- name: Execute Integration Tests | ||
shell: pwsh | ||
|
@@ -124,8 +123,10 @@ jobs: | |
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Setup NuGet.exe | ||
uses: NuGet/[email protected] | ||
- name: Setup .NET SDK | ||
uses: actions/setup-dotnet@v1 | ||
with: | ||
dotnet-version: ${{ env.dotnet_sdk_version }} | ||
|
||
- name: Download package artifacts | ||
uses: actions/download-artifact@v2 | ||
|
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 |
---|---|---|
@@ -1 +1 @@ | ||
5.0.0 | ||
5.1.0 |
2 changes: 1 addition & 1 deletion
2
src/Moryx.AbstractionLayer.TestTools/Moryx.AbstractionLayer.TestTools.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
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,43 @@ | ||
// Copyright (c) 2020, Phoenix Contact GmbH & Co. KG | ||
// Licensed under the Apache License, Version 2.0 | ||
|
||
using System; | ||
using Moryx.Tools; | ||
|
||
namespace Moryx.AbstractionLayer | ||
{ | ||
/// <summary> | ||
/// Base class for parameters | ||
/// </summary> | ||
#pragma warning disable 618 //TODO: Remove if ParametersBase was removed | ||
public abstract class Parameters : ParametersBase | ||
{ | ||
/// <summary> | ||
/// Method to create a new instance of this parameters | ||
/// </summary> | ||
private Func<Parameters> _instanceDelegate; | ||
|
||
/// <summary> | ||
/// Resolve the binding parameters | ||
/// </summary> | ||
/// <param name="process">Process to bind to</param> | ||
/// <returns>Parameters with resolved bindings</returns> | ||
protected sealed override ParametersBase ResolveBinding(IProcess process) | ||
{ | ||
if (_instanceDelegate == null) | ||
_instanceDelegate = ReflectionTool.ConstructorDelegate<Parameters>(GetType()); | ||
|
||
var instance = _instanceDelegate(); | ||
Populate(process, instance); | ||
return instance; | ||
} | ||
|
||
/// <summary> | ||
/// Populates the given instance with parameters | ||
/// </summary> | ||
/// <param name="instance">New instance of this type</param> | ||
/// <param name="process">Process to bind to</param> | ||
protected abstract void Populate(IProcess process, Parameters instance); | ||
} | ||
#pragma warning restore 618 | ||
} |
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
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
Oops, something went wrong.