diff --git a/COMET.Web.Common.Tests/Components/Applications/SingleEngineeringModelApplicationTemplateTestFixture.cs b/COMET.Web.Common.Tests/Components/Applications/SingleEngineeringModelApplicationTemplateTestFixture.cs index f96bc8fe..ddfcbdc9 100644 --- a/COMET.Web.Common.Tests/Components/Applications/SingleEngineeringModelApplicationTemplateTestFixture.cs +++ b/COMET.Web.Common.Tests/Components/Applications/SingleEngineeringModelApplicationTemplateTestFixture.cs @@ -37,6 +37,7 @@ namespace COMET.Web.Common.Tests.Components.Applications using COMET.Web.Common.Components.Applications; using COMET.Web.Common.Components.Selectors; using COMET.Web.Common.Model.Configuration; + using COMET.Web.Common.Services.Cache; using COMET.Web.Common.Services.ConfigurationService; using COMET.Web.Common.Services.SessionManagement; using COMET.Web.Common.Services.StringTableService; @@ -70,6 +71,7 @@ public void Setup() this.viewModel = new Mock(); this.openEngineeringModels = []; + var cacheService = new Mock(); var sessionService = new Mock(); sessionService.Setup(x => x.OpenEngineeringModels).Returns(this.openEngineeringModels); sessionService.Setup(x => x.OpenIterations).Returns(new SourceList()); @@ -84,6 +86,7 @@ public void Setup() this.context.Services.AddSingleton(mockConfigurationService.Object); this.context.Services.AddSingleton(new Mock().Object); this.context.Services.AddSingleton(sessionService.Object); + this.context.Services.AddSingleton(cacheService.Object); this.context.ConfigureDevExpressBlazor(); } diff --git a/COMETwebapp.Tests/Pages/ModelDashboard/ModelDashboardTestFixture.cs b/COMETwebapp.Tests/Pages/ModelDashboard/ModelDashboardTestFixture.cs index 283dbab0..1b8569da 100644 --- a/COMETwebapp.Tests/Pages/ModelDashboard/ModelDashboardTestFixture.cs +++ b/COMETwebapp.Tests/Pages/ModelDashboard/ModelDashboardTestFixture.cs @@ -35,6 +35,7 @@ namespace COMETwebapp.Tests.Pages.ModelDashboard using COMET.Web.Common.Components.Selectors; using COMET.Web.Common.Extensions; using COMET.Web.Common.Model.Configuration; + using COMET.Web.Common.Services.Cache; using COMET.Web.Common.Services.ConfigurationService; using COMET.Web.Common.Services.SessionManagement; using COMET.Web.Common.Services.StringTableService; @@ -66,6 +67,7 @@ public class ModelDashboardTestFixture private TestContext context; private ISingleIterationApplicationTemplateViewModel viewModel; private Mock sessionService; + private Mock cacheService; private SourceList openedIterations; private Mock session; private Iteration firstIteration; @@ -77,6 +79,7 @@ public void Setup() { this.context = new TestContext(); this.sessionService = new Mock(); + this.cacheService = new Mock(); this.openedIterations = new SourceList(); this.sessionService.Setup(x => x.OpenIterations).Returns(this.openedIterations); this.viewModel = new SingleIterationApplicationTemplateViewModel(this.sessionService.Object, new IterationSelectorViewModel()); @@ -121,6 +124,7 @@ public void Setup() this.context.ConfigureDevExpressBlazor(); this.context.Services.AddSingleton(this.viewModel); this.context.Services.AddSingleton(this.sessionService.Object); + this.context.Services.AddSingleton(this.cacheService.Object); this.context.Services.AddSingleton(mockConfigurationService.Object); this.context.Services.AddSingleton(); this.context.Services.AddSingleton(); diff --git a/COMETwebapp.Tests/Pages/ParameterEditor/ParameterEditorTestFixture.cs b/COMETwebapp.Tests/Pages/ParameterEditor/ParameterEditorTestFixture.cs index 625085f9..c338f20b 100644 --- a/COMETwebapp.Tests/Pages/ParameterEditor/ParameterEditorTestFixture.cs +++ b/COMETwebapp.Tests/Pages/ParameterEditor/ParameterEditorTestFixture.cs @@ -35,6 +35,7 @@ namespace COMETwebapp.Tests.Pages.ParameterEditor using COMET.Web.Common.Components.Selectors; using COMET.Web.Common.Extensions; using COMET.Web.Common.Model.Configuration; + using COMET.Web.Common.Services.Cache; using COMET.Web.Common.Services.ConfigurationService; using COMET.Web.Common.Services.NotificationService; using COMET.Web.Common.Services.SessionManagement; @@ -69,6 +70,7 @@ public class ParameterEditorTestFixture private TestContext context; private ISingleIterationApplicationTemplateViewModel viewModel; private Mock sessionService; + private Mock cacheService; private SourceList openedIterations; private Mock session; private Iteration firstIteration; @@ -80,6 +82,7 @@ public void Setup() { this.context = new TestContext(); this.sessionService = new Mock(); + this.cacheService = new Mock(); this.openedIterations = new SourceList(); this.sessionService.Setup(x => x.OpenIterations).Returns(this.openedIterations); this.viewModel = new SingleIterationApplicationTemplateViewModel(this.sessionService.Object, new IterationSelectorViewModel()); @@ -139,6 +142,7 @@ public void Setup() this.context.ConfigureDevExpressBlazor(); this.context.Services.AddSingleton(this.viewModel); this.context.Services.AddSingleton(this.sessionService.Object); + this.context.Services.AddSingleton(this.cacheService.Object); this.context.Services.AddSingleton(mockConfigurationService.Object); this.context.Services.AddSingleton(parameterEditorBodyViewModel.Object); this.context.Services.AddSingleton(parameterTableViewModel.Object); diff --git a/COMETwebapp.Tests/Pages/Viewer/ViewerTestFixture.cs b/COMETwebapp.Tests/Pages/Viewer/ViewerTestFixture.cs index b0969c62..02c5effc 100644 --- a/COMETwebapp.Tests/Pages/Viewer/ViewerTestFixture.cs +++ b/COMETwebapp.Tests/Pages/Viewer/ViewerTestFixture.cs @@ -35,6 +35,7 @@ namespace COMETwebapp.Tests.Pages.Viewer using COMET.Web.Common.Components.Selectors; using COMET.Web.Common.Extensions; using COMET.Web.Common.Model.Configuration; + using COMET.Web.Common.Services.Cache; using COMET.Web.Common.Services.ConfigurationService; using COMET.Web.Common.Services.SessionManagement; using COMET.Web.Common.Services.StringTableService; @@ -70,6 +71,7 @@ public class ViewerTestFixture private ISingleIterationApplicationTemplateViewModel viewModel; private Mock sessionService; private SourceList openedIterations; + private Mock cacheService; private Mock session; private Iteration firstIteration; private Iteration secondIteration; @@ -80,6 +82,7 @@ public void Setup() { this.context = new TestContext(); this.sessionService = new Mock(); + this.cacheService = new Mock(); this.openedIterations = new SourceList(); this.sessionService.Setup(x => x.OpenIterations).Returns(this.openedIterations); this.viewModel = new SingleIterationApplicationTemplateViewModel(this.sessionService.Object, new IterationSelectorViewModel()); @@ -125,6 +128,7 @@ public void Setup() this.context.ConfigureDevExpressBlazor(); this.context.Services.AddSingleton(this.viewModel); this.context.Services.AddSingleton(this.sessionService.Object); + this.context.Services.AddSingleton(this.cacheService.Object); this.context.Services.AddSingleton(); this.context.Services.AddSingleton(); this.context.Services.AddSingleton();