Skip to content

Commit

Permalink
Updated version number in code
Browse files Browse the repository at this point in the history
Updated docker file to fix an issue if the docker image is built on windows
Updated docker file to remove deprecation warnings
Updated dependencies to latest versions.
  • Loading branch information
MeindertN committed Sep 15, 2024
1 parent d53bc3e commit dafa8f9
Show file tree
Hide file tree
Showing 14 changed files with 374 additions and 365 deletions.
2 changes: 1 addition & 1 deletion RoboClerk.AzureDevOps/RoboClerk.AzureDevOps.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

<ItemGroup>
<PackageReference Include="HtmlAgilityPack.NetCore" Version="1.5.0.1" />
<PackageReference Include="Microsoft.TeamFoundationServer.Client" Version="16.205.1" />
<PackageReference Include="Microsoft.TeamFoundationServer.Client" Version="19.225.1" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion RoboClerk.OpenAI/RoboClerk.OpenAI.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

<ItemGroup>
<PackageReference Include="Azure.AI.OpenAI" Version="1.0.0-beta.8" />
<PackageReference Include="Samboy063.Tomlet" Version="5.2.0" />
<PackageReference Include="Samboy063.Tomlet" Version="5.4.0" />
</ItemGroup>

<ItemGroup>
Expand Down
2 changes: 1 addition & 1 deletion RoboClerk.Redmine/RoboClerk.Redmine.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="RestSharp" Version="110.2.0" />
<PackageReference Include="RestSharp" Version="112.0.0" />
</ItemGroup>

<ItemGroup>
Expand Down
12 changes: 6 additions & 6 deletions RoboClerk.Tests/RoboClerk.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@
<None Remove="TestSOUPContentCreator.cs~RF419ef34.TMP" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="coverlet.msbuild" Version="3.2.0">
<PackageReference Include="coverlet.msbuild" Version="6.0.2">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="NSubstitute" Version="4.4.0" />
<PackageReference Include="NUnit" Version="3.13.3" />
<PackageReference Include="NUnit3TestAdapter" Version="4.4.2" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.0.0" />
<PackageReference Include="System.IO.Abstractions.TestingHelpers" Version="19.2.22" />
<PackageReference Include="NSubstitute" Version="5.1.0" />
<PackageReference Include="NUnit" Version="4.2.2" />
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.11.1" />
<PackageReference Include="System.IO.Abstractions.TestingHelpers" Version="21.0.29" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\RoboClerk.AnnotatedUnitTests\RoboClerk.AnnotatedUnitTests.csproj" />
Expand Down
37 changes: 19 additions & 18 deletions RoboClerk.Tests/TestCheckpointDataStorage.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using NUnit.Framework;
using NUnit.Framework.Legacy;
using System.Collections.Generic;


Expand Down Expand Up @@ -60,15 +61,15 @@ public void CreateCheckpointDataStorage2()
sst.Anomalies = anomalies;
sst.DocContents = docContents;

Assert.AreSame(systemRequirements, sst.SystemRequirements);
Assert.AreSame(softwareRequirements, sst.SoftwareRequirements);
Assert.AreSame(documentationRequirements, sst.DocumentationRequirements);
Assert.AreSame(risks, sst.Risks);
Assert.AreSame(soups, sst.SOUPs);
Assert.AreSame(unitTests, sst.UnitTests);
Assert.AreSame(softwareSystemTests,sst.SoftwareSystemTests);
Assert.AreSame(anomalies, sst.Anomalies);
Assert.AreSame(docContents, sst.DocContents);
ClassicAssert.AreSame(systemRequirements, sst.SystemRequirements);
ClassicAssert.AreSame(softwareRequirements, sst.SoftwareRequirements);
ClassicAssert.AreSame(documentationRequirements, sst.DocumentationRequirements);
ClassicAssert.AreSame(risks, sst.Risks);
ClassicAssert.AreSame(soups, sst.SOUPs);
ClassicAssert.AreSame(unitTests, sst.UnitTests);
ClassicAssert.AreSame(softwareSystemTests,sst.SoftwareSystemTests);
ClassicAssert.AreSame(anomalies, sst.Anomalies);
ClassicAssert.AreSame(docContents, sst.DocContents);
}

[UnitTestAttribute(
Expand Down Expand Up @@ -131,15 +132,15 @@ public void CreateCheckpointDataStorage3()
Assert.That(sst.Anomalies[0].ItemCategory, Is.EqualTo("new"));
Assert.That(sst.DocContents[0].ItemCategory, Is.EqualTo("new"));

Assert.AreSame(systemRequirements, sst.SystemRequirements);
Assert.AreSame(softwareRequirements, sst.SoftwareRequirements);
Assert.AreSame(documentationRequirements, sst.DocumentationRequirements);
Assert.AreSame(risks, sst.Risks);
Assert.AreSame(soups, sst.SOUPs);
Assert.AreSame(unitTests, sst.UnitTests);
Assert.AreSame(softwareSystemTests, sst.SoftwareSystemTests);
Assert.AreSame(anomalies, sst.Anomalies);
Assert.AreSame(docContents, sst.DocContents);
ClassicAssert.AreSame(systemRequirements, sst.SystemRequirements);
ClassicAssert.AreSame(softwareRequirements, sst.SoftwareRequirements);
ClassicAssert.AreSame(documentationRequirements, sst.DocumentationRequirements);
ClassicAssert.AreSame(risks, sst.Risks);
ClassicAssert.AreSame(soups, sst.SOUPs);
ClassicAssert.AreSame(unitTests, sst.UnitTests);
ClassicAssert.AreSame(softwareSystemTests, sst.SoftwareSystemTests);
ClassicAssert.AreSame(anomalies, sst.Anomalies);
ClassicAssert.AreSame(docContents, sst.DocContents);
}


Expand Down
91 changes: 46 additions & 45 deletions RoboClerk.Tests/TestDatasources.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
using NUnit.Framework.Internal;
using System.Text;
using System.Linq;
using NUnit.Framework.Legacy;

namespace RoboClerk.Tests
{
Expand Down Expand Up @@ -190,10 +191,10 @@ public void System_Requirements_Can_Be_Retrieved_VERIFIES_Supplied_Requirements_
SetupSLMSPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedReqs = ds.GetAllSystemRequirements();
Assert.AreSame(SYSs[0], returnedReqs[0]);
Assert.AreSame(SYSs[1], returnedReqs[1]);
Assert.AreSame(SYSs[1], ds.GetSystemRequirement("SYS_id2"));
Assert.AreSame(SYSs[0], ds.GetItem("SYS_id1"));
ClassicAssert.AreSame(SYSs[0], returnedReqs[0]);
ClassicAssert.AreSame(SYSs[1], returnedReqs[1]);
ClassicAssert.AreSame(SYSs[1], ds.GetSystemRequirement("SYS_id2"));
ClassicAssert.AreSame(SYSs[0], ds.GetItem("SYS_id1"));
var returnedItems = ds.GetItems(new TraceEntity("SystemRequirement", "Requirement", "SYS", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(SYSs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(SYSs[1].ItemID));
Expand All @@ -205,10 +206,10 @@ public void Software_Requirements_Can_Be_Retrieved_VERIFIES_Supplied_Requirement
SetupSLMSPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedReqs = ds.GetAllSoftwareRequirements();
Assert.AreSame(SWRs[0], returnedReqs[0]);
Assert.AreSame(SWRs[1], returnedReqs[1]);
Assert.AreSame(SWRs[1], ds.GetSoftwareRequirement("SWR_id2"));
Assert.AreSame(SWRs[0], ds.GetItem("SWR_id1"));
ClassicAssert.AreSame(SWRs[0], returnedReqs[0]);
ClassicAssert.AreSame(SWRs[1], returnedReqs[1]);
ClassicAssert.AreSame(SWRs[1], ds.GetSoftwareRequirement("SWR_id2"));
ClassicAssert.AreSame(SWRs[0], ds.GetItem("SWR_id1"));
var returnedItems = ds.GetItems(new TraceEntity("SoftwareRequirement", "Requirement", "SWR", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(SWRs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(SWRs[1].ItemID));
Expand All @@ -220,10 +221,10 @@ public void Documentation_Requirements_Can_Be_Retrieved_VERIFIES_Supplied_Requir
SetupSLMSPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedReqs = ds.GetAllDocumentationRequirements();
Assert.AreSame(DOCs[0], returnedReqs[0]);
Assert.AreSame(DOCs[1], returnedReqs[1]);
Assert.AreSame(DOCs[1], ds.GetDocumentationRequirement("DOC_id2"));
Assert.AreSame(DOCs[0], ds.GetItem("DOC_id1"));
ClassicAssert.AreSame(DOCs[0], returnedReqs[0]);
ClassicAssert.AreSame(DOCs[1], returnedReqs[1]);
ClassicAssert.AreSame(DOCs[1], ds.GetDocumentationRequirement("DOC_id2"));
ClassicAssert.AreSame(DOCs[0], ds.GetItem("DOC_id1"));
var returnedItems = ds.GetItems(new TraceEntity("DocumentationRequirement", "Requirement", "DOC", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(DOCs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(DOCs[1].ItemID));
Expand All @@ -235,10 +236,10 @@ public void DocContents_Can_Be_Retrieved_VERIFIES_Supplied_DocContents_Are_Retur
SetupSLMSPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedDCTs = ds.GetAllDocContents();
Assert.AreSame(DOCCTs[0], returnedDCTs[0]);
Assert.AreSame(DOCCTs[1], returnedDCTs[1]);
Assert.AreSame(DOCCTs[1], ds.GetDocContent("DOCCT_id2"));
Assert.AreSame(DOCCTs[0], ds.GetItem("DOCCT_id1"));
ClassicAssert.AreSame(DOCCTs[0], returnedDCTs[0]);
ClassicAssert.AreSame(DOCCTs[1], returnedDCTs[1]);
ClassicAssert.AreSame(DOCCTs[1], ds.GetDocContent("DOCCT_id2"));
ClassicAssert.AreSame(DOCCTs[0], ds.GetItem("DOCCT_id1"));
var returnedItems = ds.GetItems(new TraceEntity("DocContent", "Content", "DOCCT", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(DOCCTs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(DOCCTs[1].ItemID));
Expand All @@ -250,10 +251,10 @@ public void Test_Cases_Can_Be_Retrieved_VERIFIES_Supplied_Test_Cases_Are_Returne
SetupSLMSPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedReqs = ds.GetAllSoftwareSystemTests();
Assert.AreSame(TCs[0], returnedReqs[0]);
Assert.AreSame(TCs[1], returnedReqs[1]);
Assert.AreSame(TCs[1], ds.GetSoftwareSystemTest("TC_id2"));
Assert.AreSame(TCs[0], ds.GetItem("TC_id1"));
ClassicAssert.AreSame(TCs[0], returnedReqs[0]);
ClassicAssert.AreSame(TCs[1], returnedReqs[1]);
ClassicAssert.AreSame(TCs[1], ds.GetSoftwareSystemTest("TC_id2"));
ClassicAssert.AreSame(TCs[0], ds.GetItem("TC_id1"));
var returnedItems = ds.GetItems(new TraceEntity("SoftwareSystemTest", "System Level Test", "SLT", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(TCs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(TCs[1].ItemID));
Expand All @@ -266,10 +267,10 @@ public void SOUP_Items_Can_Be_Retrieved_VERIFIES_Supplied_SOUP_Items_Are_Returne
SetupSrcCodePlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedSOUP = ds.GetAllSOUP();
Assert.AreSame(SOUPs[0], returnedSOUP[0]);
Assert.AreSame(SOUPs[1], returnedSOUP[1]);
Assert.AreSame(SOUPs[1], ds.GetSOUP("SOUP_id2"));
Assert.AreSame(SOUPs[0], ds.GetItem("SOUP_id1"));
ClassicAssert.AreSame(SOUPs[0], returnedSOUP[0]);
ClassicAssert.AreSame(SOUPs[1], returnedSOUP[1]);
ClassicAssert.AreSame(SOUPs[1], ds.GetSOUP("SOUP_id2"));
ClassicAssert.AreSame(SOUPs[0], ds.GetItem("SOUP_id1"));
var returnedItems = ds.GetItems(new TraceEntity("SOUP", "SOUP", "OTS", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(SOUPs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(SOUPs[1].ItemID));
Expand All @@ -282,10 +283,10 @@ public void RISKs_Can_Be_Retrieved_VERIFIES_Supplied_RISKs_Are_Returned()
SetupSrcCodePlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedRISKs = ds.GetAllRisks();
Assert.AreSame(RISKs[0], returnedRISKs[0]);
Assert.AreSame(RISKs[1], returnedRISKs[1]);
Assert.AreSame(RISKs[1], ds.GetRisk("RISK_id2"));
Assert.AreSame(RISKs[0], ds.GetItem("RISK_id1"));
ClassicAssert.AreSame(RISKs[0], returnedRISKs[0]);
ClassicAssert.AreSame(RISKs[1], returnedRISKs[1]);
ClassicAssert.AreSame(RISKs[1], ds.GetRisk("RISK_id2"));
ClassicAssert.AreSame(RISKs[0], ds.GetItem("RISK_id1"));
var returnedItems = ds.GetItems(new TraceEntity("Risk", "Risk", "RSK", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(RISKs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(RISKs[1].ItemID));
Expand All @@ -298,12 +299,12 @@ public void Unit_Tests_Can_Be_Retrieved_VERIFIES_Supplied_Unit_Tests_Are_Returne
SetupSrcCodePlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedUTs = ds.GetAllUnitTests();
Assert.AreSame(SLMSUTs[0], returnedUTs[0]);
Assert.AreSame(SLMSUTs[1], returnedUTs[1]);
Assert.AreSame(SRCUTs[0], returnedUTs[2]);
Assert.AreSame(SRCUTs[1], returnedUTs[3]);
Assert.AreSame(returnedUTs[2], ds.GetUnitTest("UT_id3"));
Assert.AreSame(returnedUTs[0], ds.GetItem("UT_id1"));
ClassicAssert.AreSame(SLMSUTs[0], returnedUTs[0]);
ClassicAssert.AreSame(SLMSUTs[1], returnedUTs[1]);
ClassicAssert.AreSame(SRCUTs[0], returnedUTs[2]);
ClassicAssert.AreSame(SRCUTs[1], returnedUTs[3]);
ClassicAssert.AreSame(returnedUTs[2], ds.GetUnitTest("UT_id3"));
ClassicAssert.AreSame(returnedUTs[0], ds.GetItem("UT_id1"));
var returnedItems = ds.GetItems(new TraceEntity("UnitTest", "Unit Test", "UT", TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID, Is.EqualTo(SLMSUTs[0].ItemID));
Assert.That(returnedItems[2].ItemID, Is.EqualTo(SRCUTs[0].ItemID));
Expand All @@ -316,11 +317,11 @@ public void Anomalies_Can_Be_Retrieved_VERIFIES_Supplied_Anomalies_Are_Returned(
SetupSrcCodePlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedAnomalies = ds.GetAllAnomalies();
Assert.IsTrue(returnedAnomalies.Count > 0);
Assert.AreSame(ANOMALYs[0], returnedAnomalies[0]);
Assert.AreSame(ANOMALYs[1], returnedAnomalies[1]);
Assert.AreSame(ANOMALYs[1], ds.GetAnomaly("ANOMALY_id2"));
Assert.AreSame(ANOMALYs[0], ds.GetItem("ANOMALY_id1"));
ClassicAssert.IsTrue(returnedAnomalies.Count > 0);
ClassicAssert.AreSame(ANOMALYs[0], returnedAnomalies[0]);
ClassicAssert.AreSame(ANOMALYs[1], returnedAnomalies[1]);
ClassicAssert.AreSame(ANOMALYs[1], ds.GetAnomaly("ANOMALY_id2"));
ClassicAssert.AreSame(ANOMALYs[0], ds.GetItem("ANOMALY_id1"));
var returnedItems = ds.GetItems(new TraceEntity("Anomaly","Bug","Bug",TraceEntityType.Truth));
Assert.That(returnedItems[0].ItemID,Is.EqualTo(ANOMALYs[0].ItemID));
Assert.That(returnedItems[1].ItemID, Is.EqualTo(ANOMALYs[1].ItemID));
Expand All @@ -343,9 +344,9 @@ public void External_Dependencies_Can_Be_Retrieved_VERIFIES_Supplied_External_De
SetupDepPlugin();
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
var returnedDeps = ds.GetAllExternalDependencies();
Assert.IsTrue(returnedDeps.Count > 0);
Assert.AreSame(DEPs[0], returnedDeps[0]);
Assert.AreSame(DEPs[1], returnedDeps[1]);
ClassicAssert.IsTrue(returnedDeps.Count > 0);
ClassicAssert.AreSame(DEPs[0], returnedDeps[0]);
ClassicAssert.AreSame(DEPs[1], returnedDeps[1]);
}


Expand All @@ -356,7 +357,7 @@ public void GetItem_Can_Handle_Missing_ID_VERIFIES_Null_Returned_For_Missing_ID(
SetupSrcCodePlugin();
var ds = new PluginDataSources(mockConfiguration,mockPluginLoader, mockFileSystem);
var result = ds.GetItem("does not exist");
Assert.AreSame(null, result);
ClassicAssert.AreSame(null, result);
}

[Test]
Expand All @@ -369,8 +370,8 @@ public void Configuration_Data_Items_Are_Retrieved_VERIFIES_Supplied_Data_Item_M
vals.FromToml(table);
mockConfiguration.ConfigVals.Returns(vals);
var ds = new PluginDataSources(mockConfiguration, mockPluginLoader, mockFileSystem);
Assert.AreSame("TestValue",ds.GetConfigValue("testKey"));
Assert.AreSame("NOT FOUND", ds.GetConfigValue("estKey"));
ClassicAssert.AreSame("TestValue",ds.GetConfigValue("testKey"));
ClassicAssert.AreSame("NOT FOUND", ds.GetConfigValue("estKey"));
}

[Test]
Expand Down
11 changes: 6 additions & 5 deletions RoboClerk.Tests/TestPromptTemplate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using NUnit.Framework;
using System.Collections.Generic;
using RoboClerk.AISystem;
using NUnit.Framework.Legacy;

namespace RoboClerk.Tests
{
Expand Down Expand Up @@ -35,7 +36,7 @@ public void TestPrompt2()
string template = "";
var tpe = new PromptTemplate(template);
Dictionary<string,string> parameters = new Dictionary<string,string>();
Assert.IsTrue(tpe.GetPrompt(parameters) == "");
ClassicAssert.IsTrue(tpe.GetPrompt(parameters) == "");
}

[UnitTestAttribute(
Expand All @@ -49,7 +50,7 @@ public void TestPrompt3()
var tpe = new PromptTemplate(template);
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters["RequirementDescription"] = "true";
Assert.IsTrue(tpe.GetPrompt(parameters) == "");
ClassicAssert.IsTrue(tpe.GetPrompt(parameters) == "");
}

[UnitTestAttribute(
Expand All @@ -63,7 +64,7 @@ public void TestPrompt4()
var tpe = new PromptTemplate(template);
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters["pArvAl"] = "true";
Assert.IsTrue(tpe.GetPrompt(parameters) == "true");
ClassicAssert.IsTrue(tpe.GetPrompt(parameters) == "true");
}

[UnitTestAttribute(
Expand All @@ -77,7 +78,7 @@ public void TestPrompt5()
var tpe = new PromptTemplate(template);
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters["pArvAl_non_matching"] = "true";
Assert.IsTrue(tpe.GetPrompt(parameters) == "parval");
ClassicAssert.IsTrue(tpe.GetPrompt(parameters) == "parval");
}

[UnitTestAttribute(
Expand All @@ -93,7 +94,7 @@ public void TestPrompt6()
var tpe = new PromptTemplate(template);
Dictionary<string, string> parameters = new Dictionary<string, string>();
parameters["pArvAl_non_matching"] = "true";
Assert.IsTrue(tpe.GetPrompt(parameters,item) == "test string");
ClassicAssert.IsTrue(tpe.GetPrompt(parameters,item) == "test string");
}
}

Expand Down
Loading

0 comments on commit dafa8f9

Please sign in to comment.