From 404b568d9aa814ce29193f5504157369dffba46b Mon Sep 17 00:00:00 2001 From: Temo Nikolaishvili Date: Mon, 5 Jan 2026 15:13:12 +0400 Subject: [PATCH 1/2] Moved to central package management --- .github/workflows/publish_nuget.yml | 3 +++ AltaSoft.Simpra.sln | 19 +++++++++++++-- Directory.Build.props | 12 +++++++++- Directory.Packages.props | 23 +++++++++++++++++++ .../AltaSoft.Simpra.Metadata.csproj | 10 +++++--- src/AltaSoft.Simpra/AltaSoft.Simpra.csproj | 7 +++--- .../AltaSoft.Simpra.Benchmark.csproj | 4 ++-- .../AltaSoft.Simpra.Tests.csproj | 14 +++++------ .../AltaSoft.Simpra.tests/Models/TestModel.cs | 8 +++---- .../AltaSoft.Simpra.tests/Models/Transfer.cs | 6 ++--- .../SimpraExpressionTests.cs | 2 +- .../SimpraMetaDataTest.cs | 10 ++++---- .../UnitTestsSmartPurposeModel.cs | 2 -- 13 files changed, 87 insertions(+), 33 deletions(-) create mode 100644 Directory.Packages.props diff --git a/.github/workflows/publish_nuget.yml b/.github/workflows/publish_nuget.yml index c970bef..e5bfc0e 100644 --- a/.github/workflows/publish_nuget.yml +++ b/.github/workflows/publish_nuget.yml @@ -35,3 +35,6 @@ jobs: - name: Publish run: dotnet nuget push "nupkg/*.nupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json + + - name: Publish Snupkg + run: dotnet nuget push "nupkg/*.snupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json diff --git a/AltaSoft.Simpra.sln b/AltaSoft.Simpra.sln index 3c0b6a8..977ba63 100644 --- a/AltaSoft.Simpra.sln +++ b/AltaSoft.Simpra.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio Version 17 -VisualStudioVersion = 17.0.31903.59 +# Visual Studio Version 18 +VisualStudioVersion = 18.1.11312.151 MinimumVisualStudioVersion = 10.0.40219.1 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AltaSoft.Simpra", "src\AltaSoft.Simpra\AltaSoft.Simpra.csproj", "{8141457D-F0B4-42C7-8C35-87B1CA94E705}" EndProject @@ -14,9 +14,19 @@ EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{8EC462FD-D22E-90A8-E5CE-7E832BA40C5D}" ProjectSection(SolutionItems) = preProject Directory.Build.props = Directory.Build.props + Directory.Packages.props = Directory.Packages.props README.md = README.md EndProjectSection EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Tests", "Tests", "{C35F7D98-8981-47C6-A4FD-1ECB01BB940C}" +EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".github", ".github", "{A3869290-51B5-4402-95E6-E95D75A72ABA}" + ProjectSection(SolutionItems) = preProject + .github\workflows\build_nuget_dont_publish.yml = .github\workflows\build_nuget_dont_publish.yml + .github\workflows\dotnet.yml = .github\workflows\dotnet.yml + .github\workflows\publish_nuget.yml = .github\workflows\publish_nuget.yml + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Any CPU = Debug|Any CPU @@ -43,6 +53,11 @@ Global GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(NestedProjects) = preSolution + {BC2F2760-4322-4C79-B476-9882A65491F8} = {C35F7D98-8981-47C6-A4FD-1ECB01BB940C} + {718B360D-CA84-FE14-AEC3-59E8ACBFC78D} = {C35F7D98-8981-47C6-A4FD-1ECB01BB940C} + {A3869290-51B5-4402-95E6-E95D75A72ABA} = {8EC462FD-D22E-90A8-E5CE-7E832BA40C5D} + EndGlobalSection GlobalSection(ExtensibilityGlobals) = postSolution SolutionGuid = {D84BAEEA-E226-4291-A9E6-A900751C5004} EndGlobalSection diff --git a/Directory.Build.props b/Directory.Build.props index 6852b86..a0bc7a2 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -1,15 +1,17 @@ + net8.0;net9.0;net10.0 Library enable Latest true + latest ALTA Software llc. Simpra ALTA Software llc. Copyright © 2024 ALTA Software llc. - 1.0.16 + 2.0.0 @@ -29,4 +31,12 @@ + + + embedded + true + false + true + true + diff --git a/Directory.Packages.props b/Directory.Packages.props new file mode 100644 index 0000000..9c78cc2 --- /dev/null +++ b/Directory.Packages.props @@ -0,0 +1,23 @@ + + + true + + + + + + + + + + + + + + + + + + + + diff --git a/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj b/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj index bd70d46..64a73ec 100644 --- a/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj +++ b/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj @@ -2,15 +2,19 @@ net9.0;net8.0 - Latest - enable true true $(NoWarn);CS1591;CS1701;CS1702;NU1507 + true + snupkg - + + + + + diff --git a/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj b/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj index b79e1b6..d7797a0 100644 --- a/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj +++ b/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj @@ -2,12 +2,13 @@ net9.0;net8.0 - enable + true + snupkg - - + + diff --git a/tests/AltaSoft.Simpra.Benchmark/AltaSoft.Simpra.Benchmark.csproj b/tests/AltaSoft.Simpra.Benchmark/AltaSoft.Simpra.Benchmark.csproj index 561d138..4d1d4cb 100644 --- a/tests/AltaSoft.Simpra.Benchmark/AltaSoft.Simpra.Benchmark.csproj +++ b/tests/AltaSoft.Simpra.Benchmark/AltaSoft.Simpra.Benchmark.csproj @@ -1,4 +1,4 @@ - + Exe @@ -9,7 +9,7 @@ - + diff --git a/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj b/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj index da7a38f..3ddb4e0 100644 --- a/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj +++ b/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj @@ -1,4 +1,4 @@ - + net8.0 @@ -11,16 +11,16 @@ - - + + - + all runtime; build; native; contentfiles; analyzers; buildtransitive - - - + + + all runtime; build; native; contentfiles; analyzers; buildtransitive diff --git a/tests/AltaSoft.Simpra.tests/Models/TestModel.cs b/tests/AltaSoft.Simpra.tests/Models/TestModel.cs index 24f9f89..7c5a94d 100644 --- a/tests/AltaSoft.Simpra.tests/Models/TestModel.cs +++ b/tests/AltaSoft.Simpra.tests/Models/TestModel.cs @@ -13,11 +13,11 @@ public class ListModel } public interface ICustomerModel { - public Customer Customer { get; set; } + Customer Customer { get; set; } } public interface ITransferModel : ICustomerModel { - public Transfer? Transfer { get; set; } + Transfer? Transfer { get; set; } } @@ -41,11 +41,11 @@ public class TestModel : BaseModel, ITransferModel public int? Nint1 { get; set; } public short Nint2 { get; set; } = 20; public Xy Xy { get; set; } = new() { X = 1, Y = 2 }; - public string Ccy { get; set; } = "GEL"; + public string? Ccy { get; set; } = "GEL"; public IEnumerable Values { get; set; } = [1, 2, 3]; public NonNegativeAmount? NullableAmount { get; set; } public int? NullableIntegerProperty { get; set; } - public List CustomerList { get; set; } + public List? CustomerList { get; set; } } diff --git a/tests/AltaSoft.Simpra.tests/Models/Transfer.cs b/tests/AltaSoft.Simpra.tests/Models/Transfer.cs index b0033c9..7a90a7a 100644 --- a/tests/AltaSoft.Simpra.tests/Models/Transfer.cs +++ b/tests/AltaSoft.Simpra.tests/Models/Transfer.cs @@ -3,7 +3,7 @@ public class Transfer { public decimal Amount { get; set; } - public Customer2 Customer { get; set; } + public Customer2? Customer { get; set; } public required string Currency { get; set; } public List? A { get; set; } public List? OuterList { get; set; } @@ -11,10 +11,10 @@ public class Transfer public class TypeWithInnerList { - public List InnerList { get; set; } + public required List InnerList { get; set; } } public class Customer2 { public int Id { get; set; } - public string Name { get; set; } + public required string Name { get; set; } } diff --git a/tests/AltaSoft.Simpra.tests/SimpraExpressionTests.cs b/tests/AltaSoft.Simpra.tests/SimpraExpressionTests.cs index 3d99ba6..2e8a1f5 100644 --- a/tests/AltaSoft.Simpra.tests/SimpraExpressionTests.cs +++ b/tests/AltaSoft.Simpra.tests/SimpraExpressionTests.cs @@ -140,7 +140,7 @@ public void BuiltInFunction_Substring_StartOnly_NullSource_ShouldBeEmpty() model.Ccy = null; var result = simpra.Execute(model, new TestFunctions(), "return substring(Ccy,1)"); - Assert.Equal(null, result); + Assert.Null(result); } [Fact] diff --git a/tests/AltaSoft.Simpra.tests/SimpraMetaDataTest.cs b/tests/AltaSoft.Simpra.tests/SimpraMetaDataTest.cs index c64d24b..edd7228 100644 --- a/tests/AltaSoft.Simpra.tests/SimpraMetaDataTest.cs +++ b/tests/AltaSoft.Simpra.tests/SimpraMetaDataTest.cs @@ -75,10 +75,10 @@ public class MyChildClass : MyClass public required string Name { get; set; } [XmlIgnore] public int Age { get; set; } - public MyClass1[] CollectionClass1 { get; set; } - public CountryCode[] Countries { get; set; } - public CountryCode Country { get; set; } - public Dictionary Dictionary { get; set; } + public required MyClass1[] CollectionClass1 { get; set; } + public required CountryCode[] Countries { get; set; } + public required CountryCode Country { get; set; } + public required Dictionary Dictionary { get; set; } public void Child() { @@ -97,5 +97,5 @@ public void Father() public class MyClass1 { public int Info { get; set; } - public List CollectionMyClasses { get; set; } + public required List CollectionMyClasses { get; set; } } diff --git a/tests/AltaSoft.Simpra.tests/UnitTestsSmartPurposeModel.cs b/tests/AltaSoft.Simpra.tests/UnitTestsSmartPurposeModel.cs index 715cf32..3432dbd 100644 --- a/tests/AltaSoft.Simpra.tests/UnitTestsSmartPurposeModel.cs +++ b/tests/AltaSoft.Simpra.tests/UnitTestsSmartPurposeModel.cs @@ -27,5 +27,3 @@ public void SetValue(string key, string? value) public string GetValue(string key) => P.TryGetValue(key, out var result) ? result : string.Empty; } - - From 4f8f962e462ff80e0967d5ef569b63a09a06764f Mon Sep 17 00:00:00 2001 From: Temo Nikolaishvili Date: Mon, 12 Jan 2026 14:31:34 +0400 Subject: [PATCH 2/2] Updated target frameworks and upgraded dependencies. Centralized framework configuration, updated CI workflows, and revised build/test properties. --- .github/workflows/build_nuget_dont_publish.yml | 1 + .github/workflows/dotnet.yml | 1 + .github/workflows/publish_nuget.yml | 4 +--- Directory.Build.props | 4 +--- Directory.Packages.props | 18 ++++++------------ .../AltaSoft.Simpra.Metadata.csproj | 3 ++- src/AltaSoft.Simpra/AltaSoft.Simpra.csproj | 3 ++- .../AltaSoft.Simpra.Tests.csproj | 4 ++-- 8 files changed, 16 insertions(+), 22 deletions(-) diff --git a/.github/workflows/build_nuget_dont_publish.yml b/.github/workflows/build_nuget_dont_publish.yml index a653442..5876aeb 100644 --- a/.github/workflows/build_nuget_dont_publish.yml +++ b/.github/workflows/build_nuget_dont_publish.yml @@ -14,6 +14,7 @@ jobs: uses: actions/setup-dotnet@v1 with: dotnet-version: | + 10.0.x 9.0.x 8.0.x diff --git a/.github/workflows/dotnet.yml b/.github/workflows/dotnet.yml index e46d307..30b5129 100644 --- a/.github/workflows/dotnet.yml +++ b/.github/workflows/dotnet.yml @@ -26,6 +26,7 @@ jobs: uses: actions/setup-dotnet@v3 with: dotnet-version: | + 10.0.x 9.0.x 8.0.x diff --git a/.github/workflows/publish_nuget.yml b/.github/workflows/publish_nuget.yml index e5bfc0e..6c0e044 100644 --- a/.github/workflows/publish_nuget.yml +++ b/.github/workflows/publish_nuget.yml @@ -15,6 +15,7 @@ jobs: uses: actions/setup-dotnet@v1 with: dotnet-version: | + 10.0.x 9.0.x 8.0.x @@ -35,6 +36,3 @@ jobs: - name: Publish run: dotnet nuget push "nupkg/*.nupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json - - - name: Publish Snupkg - run: dotnet nuget push "nupkg/*.snupkg" -k ${{ secrets.NUGET_API_KEY }} -s https://api.nuget.org/v3/index.json diff --git a/Directory.Build.props b/Directory.Build.props index a0bc7a2..3811daa 100644 --- a/Directory.Build.props +++ b/Directory.Build.props @@ -32,11 +32,9 @@ - - embedded + true false true - true diff --git a/Directory.Packages.props b/Directory.Packages.props index 9c78cc2..756969d 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -2,22 +2,16 @@ true - - + + - - + - + - - - - - - + - + \ No newline at end of file diff --git a/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj b/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj index 64a73ec..70e9ab6 100644 --- a/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj +++ b/src/AltaSoft.Simpra.Metadata/AltaSoft.Simpra.Metadata.csproj @@ -1,12 +1,13 @@ - net9.0;net8.0 + $(DefaultTargetFrameworks) true true $(NoWarn);CS1591;CS1701;CS1702;NU1507 true snupkg + AltaSoft.Simpra.Metadata diff --git a/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj b/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj index d7797a0..758fa23 100644 --- a/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj +++ b/src/AltaSoft.Simpra/AltaSoft.Simpra.csproj @@ -1,9 +1,10 @@ - net9.0;net8.0 + $(DefaultTargetFrameworks) true snupkg + AltaSoft.Simpra diff --git a/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj b/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj index 3ddb4e0..acdf751 100644 --- a/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj +++ b/tests/AltaSoft.Simpra.tests/AltaSoft.Simpra.Tests.csproj @@ -1,7 +1,7 @@ - net8.0 + net10.0 enable enable @@ -27,7 +27,7 @@ - false + false