diff --git a/VectoCore/VectoCoreTest/Models/SimulationComponent/ATGearboxTest.cs b/VectoCore/VectoCoreTest/Models/SimulationComponent/ATGearboxTest.cs index 35d06929d6890c3b79834cdbd54b631c23906aa0..66c8ec0de8eff19e245b45107d95d4bef2b9d2d4 100644 --- a/VectoCore/VectoCoreTest/Models/SimulationComponent/ATGearboxTest.cs +++ b/VectoCore/VectoCoreTest/Models/SimulationComponent/ATGearboxTest.cs @@ -33,7 +33,6 @@ using System.Collections.Generic; using NUnit.Framework; using System.IO; using System.Linq; -using TUGraz.VECTO; using TUGraz.VectoCommon.Exceptions; using TUGraz.VectoCommon.InputData; using TUGraz.VectoCommon.Models; @@ -277,7 +276,7 @@ namespace TUGraz.VectoCore.Tests.Models.SimulationComponent vehicleInput, engineInput.EngineModes.First(), mission); //(engineInput, null, gearboxInput, new List<ITorqueLimitInputData>()); return dao.CreateGearboxData( - new MockVehicleInputData() { + new MockDeclarationVehicleInputData() { Components = new MockComponents() { GearboxInputData = gearboxInput, TorqueConverterInputData = (ITorqueConverterDeclarationInputData)gearboxInput, diff --git a/VectoCore/VectoCoreTest/Models/SimulationComponent/BatteryTest.cs b/VectoCore/VectoCoreTest/Models/SimulationComponent/BatteryTest.cs index 05e1d7820ff83adc756b4c7fc2fdbfed880cc4cd..4a0b1e9bd816f0840df1a3ad8b55b23fedbdc42a 100644 --- a/VectoCore/VectoCoreTest/Models/SimulationComponent/BatteryTest.cs +++ b/VectoCore/VectoCoreTest/Models/SimulationComponent/BatteryTest.cs @@ -3,8 +3,6 @@ using System.Collections.Generic; using System.IO; using System.Linq; using NUnit.Framework; -using TUGraz.VECTO; -using TUGraz.VectoCommon.InputData; using TUGraz.VectoCommon.Utils; using TUGraz.VectoCore.InputData.FileIO.JSON; using TUGraz.VectoCore.InputData.Reader.ComponentData; diff --git a/VectoCore/VectoCoreTest/Utils/MockBatteryInputData.cs b/VectoCore/VectoCoreTest/Utils/MockBatteryInputData.cs index 6b159e915d4cc7f2fcd8842d7d5e11dce10dd02c..2094a2676d21eb9bce8d3d62523f460a28e15270 100644 --- a/VectoCore/VectoCoreTest/Utils/MockBatteryInputData.cs +++ b/VectoCore/VectoCoreTest/Utils/MockBatteryInputData.cs @@ -1,6 +1,5 @@ using System.Collections.Generic; using System.Linq; -using TUGraz.VECTO; using TUGraz.VectoCommon.InputData; namespace TUGraz.VectoCore.Tests.Utils { diff --git a/VectoCore/VectoCoreTest/Utils/MockComponents.cs b/VectoCore/VectoCoreTest/Utils/MockComponents.cs new file mode 100644 index 0000000000000000000000000000000000000000..77b24ca5155d936233c3768888caddb968fdec30 --- /dev/null +++ b/VectoCore/VectoCoreTest/Utils/MockComponents.cs @@ -0,0 +1,35 @@ +using TUGraz.VectoCommon.InputData; + +namespace TUGraz.VectoCore.Tests.Utils +{ + public class MockComponents : IVehicleComponentsDeclaration + { + public IAirdragDeclarationInputData AirdragInputData { get; set; } + + public IGearboxDeclarationInputData GearboxInputData { get; set; } + + public ITorqueConverterDeclarationInputData TorqueConverterInputData { get; set; } + + public IAxleGearInputData AxleGearInputData { get; set; } + + public IAngledriveInputData AngledriveInputData { get; set; } + + public IEngineDeclarationInputData EngineInputData { get; set; } + + public IAuxiliariesDeclarationInputData AuxiliaryInputData { get; set; } + + public IRetarderInputData RetarderInputData { get; set; } + + public IPTOTransmissionInputData PTOTransmissionInputData { get; set; } + + public IAxlesDeclarationInputData AxleWheels { get; set; } + + public IBusAuxiliariesDeclarationData BusAuxiliaries { get; } + + public IElectricStorageSystemDeclarationInputData ElectricStorage { get; } + + public IElectricMachinesDeclarationInputData ElectricMachines { get; } + + public IIEPCDeclarationInputData IEPC { get; } + } +} \ No newline at end of file diff --git a/VectoCore/VectoCoreTest/Utils/MockDeclarationVehicleInputData.cs b/VectoCore/VectoCoreTest/Utils/MockDeclarationVehicleInputData.cs index d159b0a640ea99c8045adb722ccb5589b351ace3..04f7efa156444387d4fa75e27b27d30ad3429b30 100644 --- a/VectoCore/VectoCoreTest/Utils/MockDeclarationVehicleInputData.cs +++ b/VectoCore/VectoCoreTest/Utils/MockDeclarationVehicleInputData.cs @@ -8,7 +8,7 @@ using TUGraz.VectoCommon.Utils; using TUGraz.VectoCore.Models.SimulationComponent.Impl; namespace TUGraz.VectoCore.Tests.Utils { - public class MockDeclarationVehicleInputData : IVehicleDeclarationInputData, IVehicleComponentsDeclaration + public class MockDeclarationVehicleInputData : IVehicleDeclarationInputData { #region Implementation of IComponentInputData @@ -34,7 +34,13 @@ namespace TUGraz.VectoCore.Tests.Utils { public AxleConfiguration AxleConfiguration { get; } public Kilogram CurbMassChassis { get; } public Kilogram GrossVehicleMassRating { get; } - public IList<ITorqueLimitInputData> TorqueLimits => new List<ITorqueLimitInputData>(); + + private IList<ITorqueLimitInputData> _torqueLimits; + public IList<ITorqueLimitInputData> TorqueLimits { + get => _torqueLimits ??= new List<ITorqueLimitInputData>(); + init => _torqueLimits = value; + } + public string ManufacturerAddress { get; } public PerSecond EngineIdleSpeed { get; } public bool VocationalVehicle { get; } @@ -67,7 +73,7 @@ namespace TUGraz.VectoCore.Tests.Utils { public Dictionary<PowertrainPosition, List<Tuple<Volt, TableData>>> ElectricMotorTorqueLimits { get; } public TableData BoostingLimitations { get; } - public IVehicleComponentsDeclaration Components => this; + public IVehicleComponentsDeclaration Components { get; set; } public XmlNode XMLSource { get; } public string VehicleTypeApprovalNumber { get; } public ArchitectureID ArchitectureID { get; } diff --git a/VectoCore/VectoCoreTest/VectoCoreTest.csproj b/VectoCore/VectoCoreTest/VectoCoreTest.csproj index eeeac7e61ceda62da76d50003ac536d5dd28c103..d92e40cdb63fb3a48b03f794deecf5c15802169d 100644 --- a/VectoCore/VectoCoreTest/VectoCoreTest.csproj +++ b/VectoCore/VectoCoreTest/VectoCoreTest.csproj @@ -19,7 +19,6 @@ <ProjectReference Include="..\..\VectoCommon\VectoCommon\VectoCommon.csproj" /> <ProjectReference Include="..\..\VectoCommon\VectoHashing\VectoHashing.csproj" /> <ProjectReference Include="..\VectoCore\VectoCore.csproj" /> - <ProjectReference Include="..\..\VECTO\VECTO.vbproj" /> </ItemGroup> <ItemGroup>