diff --git a/source/Infrastructure/Configuration/CompositionRoot.cs b/source/Infrastructure/Configuration/CompositionRoot.cs index d1db44bf9f..55587ff7dc 100644 --- a/source/Infrastructure/Configuration/CompositionRoot.cs +++ b/source/Infrastructure/Configuration/CompositionRoot.cs @@ -255,16 +255,16 @@ private void AddRemoteBusinessService(string responseQueueName private void AddMessageGenerationServices() { _services.AddScoped(); - _services.AddScoped(); + _services.AddScoped(); _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); - _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); + _services.AddScoped(); _services.AddScoped(); _services.AddScoped(); } diff --git a/source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsMessageWriter.cs b/source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriter.cs similarity index 98% rename from source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriter.cs index 4d96bf5885..09e87cc059 100644 --- a/source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriter.cs @@ -24,9 +24,9 @@ namespace Infrastructure.OutgoingMessages.AccountingPointCharacteristics; -public class AccountingPointCharacteristicsMessageWriter : MessageWriter +public class AccountingPointCharacteristicsXmlDocumentWriter : MessageWriter { - public AccountingPointCharacteristicsMessageWriter(IMessageRecordParser parser) + public AccountingPointCharacteristicsXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "AccountingPointCharacteristics_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApMessageWriter.cs b/source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApDocumentWriter.cs similarity index 98% rename from source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApDocumentWriter.cs index 034991a266..17378b962e 100644 --- a/source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAp/CharacteristicsOfACustomerAtAnApDocumentWriter.cs @@ -29,11 +29,11 @@ namespace Infrastructure.OutgoingMessages.CharacteristicsOfACustomerAtAnAp; -public class CharacteristicsOfACustomerAtAnApMessageWriter : MessageWriter +public class CharacteristicsOfACustomerAtAnApDocumentWriter : MessageWriter { private MessageHeader? _header; - public CharacteristicsOfACustomerAtAnApMessageWriter(IMessageRecordParser parser) + public CharacteristicsOfACustomerAtAnApDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "CharacteristicsOfACustomerAtAnAP_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter.cs b/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs similarity index 93% rename from source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs index 37cb4c9c99..0b39cc7da3 100644 --- a/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs @@ -23,9 +23,9 @@ namespace Infrastructure.OutgoingMessages.ConfirmRequestChangeAccountingPointCharacteristics; -public class ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter : MessageWriter +public class ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter : MessageWriter { - public ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter(IMessageRecordParser parser) + public ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "ConfirmRequestChangeAccountingPointCharacteristics_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlMessageWriter.cs b/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlDocumentWriter.cs similarity index 94% rename from source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlDocumentWriter.cs index fa87e05d1b..de0e93625a 100644 --- a/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmChangeOfSupplierXmlDocumentWriter.cs @@ -23,9 +23,9 @@ namespace Infrastructure.OutgoingMessages.ConfirmRequestChangeOfSupplier; -public class ConfirmChangeOfSupplierXmlMessageWriter : MessageWriter +public class ConfirmChangeOfSupplierXmlDocumentWriter : MessageWriter { - public ConfirmChangeOfSupplierXmlMessageWriter(IMessageRecordParser parser) + public ConfirmChangeOfSupplierXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "ConfirmRequestChangeOfSupplier_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationMessageWriter.cs b/source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriter.cs similarity index 95% rename from source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriter.cs index 348d626192..05e2e2830c 100644 --- a/source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriter.cs @@ -23,9 +23,9 @@ namespace Infrastructure.OutgoingMessages.GenericNotification; -public class GenericNotificationMessageWriter : MessageWriter +public class GenericNotificationXmlDocumentWriter : MessageWriter { - public GenericNotificationMessageWriter(IMessageRecordParser parser) + public GenericNotificationXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "GenericNotification_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataMessageWriter.cs b/source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriter.cs similarity index 98% rename from source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriter.cs index b99a148b9d..90735b9cf7 100644 --- a/source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/NotifyAggregatedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriter.cs @@ -33,11 +33,11 @@ namespace Infrastructure.OutgoingMessages.NotifyAggregatedMeasureData; -public class NotifyAggregatedMeasureDataMessageWriter : MessageWriter +public class NotifyAggregatedMeasureDataXmlDocumentWriter : MessageWriter { private const string ActiveEnergy = "8716867000030"; - public NotifyAggregatedMeasureDataMessageWriter(IMessageRecordParser parser) + public NotifyAggregatedMeasureDataXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "NotifyAggregatedMeasureData_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsMessageWriter.cs b/source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs similarity index 94% rename from source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs index 6b07a583fb..aee5db61d6 100644 --- a/source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/RejectRequestChangeAccountingPointCharacteristics/RejectRequestChangeAccountingPointCharacteristicsXmlDocumentWriter.cs @@ -23,9 +23,9 @@ namespace Infrastructure.OutgoingMessages.RejectRequestChangeAccountingPointCharacteristics; -public class RejectRequestChangeAccountingPointCharacteristicsMessageWriter : MessageWriter +public class RejectRequestChangeAccountingPointCharacteristicsXmlDocumentWriter : MessageWriter { - public RejectRequestChangeAccountingPointCharacteristicsMessageWriter(IMessageRecordParser parser) + public RejectRequestChangeAccountingPointCharacteristicsXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "RejectRequestChangeAccountingPointCharacteristics_MarketDocument", diff --git a/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonMessageWriter.cs b/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriter.cs similarity index 96% rename from source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriter.cs index 468e9703f1..76c0c8e9d6 100644 --- a/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriter.cs @@ -24,13 +24,13 @@ namespace Infrastructure.OutgoingMessages.RejectRequestChangeOfSupplier; -public class RejectRequestChangeOfSupplierJsonMessageWriter : IMessageWriter +public class RejectRequestChangeOfSupplierJsonDocumentWriter : IMessageWriter { private const string DocumentType = "RejectRequestChangeOfSupplier_MarketDocument"; private const string TypeCode = "414"; private readonly IMessageRecordParser _parser; - public RejectRequestChangeOfSupplierJsonMessageWriter(IMessageRecordParser parser) + public RejectRequestChangeOfSupplierJsonDocumentWriter(IMessageRecordParser parser) { _parser = parser; } diff --git a/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlMessageWriter.cs b/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriter.cs similarity index 95% rename from source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlMessageWriter.cs rename to source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriter.cs index 798a033ffb..e6e3bcffd4 100644 --- a/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlMessageWriter.cs +++ b/source/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriter.cs @@ -23,9 +23,9 @@ namespace Infrastructure.OutgoingMessages.RejectRequestChangeOfSupplier; -public class RejectRequestChangeOfSupplierXmlMessageWriter : MessageWriter +public class RejectRequestChangeOfSupplierXmlDocumentWriter : MessageWriter { - public RejectRequestChangeOfSupplierXmlMessageWriter(IMessageRecordParser parser) + public RejectRequestChangeOfSupplierXmlDocumentWriter(IMessageRecordParser parser) : base( new DocumentDetails( "RejectRequestChangeOfSupplier_MarketDocument", diff --git a/source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriterTests.cs similarity index 87% rename from source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriterTests.cs index 31d0bfda4c..44b5ca7927 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/AccountingPointCharacteristics/AccountingPointCharacteristicsXmlDocumentWriterTests.cs @@ -32,17 +32,17 @@ namespace Tests.Infrastructure.OutgoingMessages.AccountingPointCharacteristics; -public class AccountingPointCharacteristicsDocumentWriterTests +public class AccountingPointCharacteristicsXmlDocumentWriterTests { - private readonly AccountingPointCharacteristicsMessageWriter _messageWriter; + private readonly AccountingPointCharacteristicsXmlDocumentWriter _xmlDocumentWriter; private readonly IMessageRecordParser _messageRecordParser; private readonly SampleData _sampleData; private ISchemaProvider? _schemaProvider; - public AccountingPointCharacteristicsDocumentWriterTests() + public AccountingPointCharacteristicsXmlDocumentWriterTests() { _messageRecordParser = new MessageRecordParser(new Serializer()); - _messageWriter = new AccountingPointCharacteristicsMessageWriter(_messageRecordParser); + _xmlDocumentWriter = new AccountingPointCharacteristicsXmlDocumentWriter(_messageRecordParser); _sampleData = new SampleData(); } @@ -55,7 +55,7 @@ public async Task Document_is_valid() { marketActivityRecord, }; - var message = await _messageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); } diff --git a/source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApXmlDocumentWriterTests.cs similarity index 95% rename from source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApXmlDocumentWriterTests.cs index 12714ad782..62d19e171e 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/CharacteristicsOfACustomerAtAnAP/CharacteristicsOfACustomerAtAnApXmlDocumentWriterTests.cs @@ -37,20 +37,20 @@ namespace Tests.Infrastructure.OutgoingMessages.CharacteristicsOfACustomerAtAnAP { - public class CharacteristicsOfACustomerAtAnApDocumentWriterTests : IClassFixture + public class CharacteristicsOfACustomerAtAnApXmlDocumentWriterTests : IClassFixture { private const string NamespacePrefix = "cim"; - private readonly CharacteristicsOfACustomerAtAnApMessageWriter _messageWriter; + private readonly CharacteristicsOfACustomerAtAnApDocumentWriter _documentWriter; private readonly ISystemDateTimeProvider _systemDateTimeProvider; private readonly IMessageRecordParser _messageRecordParser; private readonly DocumentValidationFixture _documentValidation; - public CharacteristicsOfACustomerAtAnApDocumentWriterTests(DocumentValidationFixture documentValidation) + public CharacteristicsOfACustomerAtAnApXmlDocumentWriterTests(DocumentValidationFixture documentValidation) { _documentValidation = documentValidation; _systemDateTimeProvider = new SystemDateTimeProvider(); _messageRecordParser = new MessageRecordParser(new Serializer()); - _messageWriter = new CharacteristicsOfACustomerAtAnApMessageWriter(_messageRecordParser); + _documentWriter = new CharacteristicsOfACustomerAtAnApDocumentWriter(_messageRecordParser); } [Fact] @@ -197,7 +197,7 @@ private MarketActivityRecord CreateMarketActivityRecord(MrId? firstCustomerId = private Task WriteDocumentAsync(MessageHeader header, params MarketActivityRecord[] marketActivityRecords) { - return _messageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()); + return _documentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()); } } } diff --git a/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriterTests.cs similarity index 88% rename from source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriterTests.cs index 4401a69f33..834d0e9dbc 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeAccountingPointCharacteristics/ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriterTests.cs @@ -33,16 +33,16 @@ namespace Tests.Infrastructure.OutgoingMessages.ConfirmRequestChangeAccountingPointCharacteristics; -public class ConfirmRequestChangeAccountingPointCharacteristicsDocumentWriterTests +public class ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriterTests { - private readonly ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter _messageWriter; + private readonly ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter _xmlDocumentWriter; private readonly IMessageRecordParser _messageRecordParser; private ISchemaProvider? _schemaProvider; - public ConfirmRequestChangeAccountingPointCharacteristicsDocumentWriterTests() + public ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriterTests() { _messageRecordParser = new MessageRecordParser(new Serializer()); - _messageWriter = new ConfirmRequestChangeAccountingPointCharacteristicsMessageWriter(_messageRecordParser); + _xmlDocumentWriter = new ConfirmRequestChangeAccountingPointCharacteristicsXmlDocumentWriter(_messageRecordParser); } [Fact] @@ -54,7 +54,7 @@ public async Task Document_is_valid() new(Guid.NewGuid().ToString(), Guid.NewGuid().ToString(), "FakeMarketEvaluationPointId"), new(Guid.NewGuid().ToString(), Guid.NewGuid().ToString(), "FakeMarketEvaluationPointId"), }; - var message = await _messageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); } diff --git a/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierXmlDocumentWriterTests.cs similarity index 88% rename from source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierXmlDocumentWriterTests.cs index c5cd7f1f8e..b8dcbf5ef4 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/ConfirmRequestChangeOfSupplier/ConfirmRequestChangeOfSupplierXmlDocumentWriterTests.cs @@ -36,16 +36,16 @@ namespace Tests.Infrastructure.OutgoingMessages.ConfirmRequestChangeOfSupplier { - public class ConfirmRequestChangeOfSupplierDocumentWriterTests + public class ConfirmRequestChangeOfSupplierXmlDocumentWriterTests { - private readonly ConfirmChangeOfSupplierXmlMessageWriter _xmlMessageWriter; + private readonly ConfirmChangeOfSupplierXmlDocumentWriter _xmlDocumentWriter; private readonly IMessageRecordParser _messageRecordParser; private ISchemaProvider? _schemaProvider; - public ConfirmRequestChangeOfSupplierDocumentWriterTests() + public ConfirmRequestChangeOfSupplierXmlDocumentWriterTests() { _messageRecordParser = new MessageRecordParser(new Serializer()); - _xmlMessageWriter = new ConfirmChangeOfSupplierXmlMessageWriter(_messageRecordParser); + _xmlDocumentWriter = new ConfirmChangeOfSupplierXmlDocumentWriter(_messageRecordParser); } [Fact] @@ -58,7 +58,7 @@ public async Task Document_is_valid() new(Guid.NewGuid().ToString(), Guid.NewGuid().ToString(), "FakeMarketEvaluationPointId"), }; - var message = await _xmlMessageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); } diff --git a/source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriterTests.cs similarity index 89% rename from source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriterTests.cs index 813aaae758..4fdc138633 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/GenericNotification/GenericNotificationXmlDocumentWriterTests.cs @@ -36,18 +36,18 @@ namespace Tests.Infrastructure.OutgoingMessages.GenericNotification { - public class GenericNotificationDocumentWriterTests + public class GenericNotificationXmlDocumentWriterTests { - private readonly GenericNotificationMessageWriter _messageWriter; + private readonly GenericNotificationXmlDocumentWriter _xmlDocumentWriter; private readonly ISystemDateTimeProvider _systemDateTimeProvider; private readonly IMessageRecordParser _messageRecordParser; private ISchemaProvider? _schemaProvider; - public GenericNotificationDocumentWriterTests() + public GenericNotificationXmlDocumentWriterTests() { _systemDateTimeProvider = new SystemDateTimeProvider(); _messageRecordParser = new MessageRecordParser(new Serializer()); - _messageWriter = new GenericNotificationMessageWriter(_messageRecordParser); + _xmlDocumentWriter = new GenericNotificationXmlDocumentWriter(_messageRecordParser); } [Fact] @@ -60,7 +60,7 @@ public async Task Document_is_valid() new(Guid.NewGuid().ToString(), Guid.NewGuid().ToString(), "FakeMarketEvaluationPointId", _systemDateTimeProvider.Now()), }; - var message = await _messageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); } diff --git a/source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriterTests.cs similarity index 97% rename from source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriterTests.cs index 037ca7dc5f..e7059f980d 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/NotifyAggreagtedMeasureData/NotifyAggregatedMeasureDataXmlDocumentWriterTests.cs @@ -39,7 +39,7 @@ namespace Tests.Infrastructure.OutgoingMessages.NotifyAggreagtedMeasureData; -public class NotifyAggregatedMeasureDataDocumentWriterTests : IClassFixture +public class NotifyAggregatedMeasureDataXmlDocumentWriterTests : IClassFixture { private const string NamespacePrefix = "cim"; private readonly DocumentValidationFixture _documentValidation; @@ -47,11 +47,11 @@ public class NotifyAggregatedMeasureDataDocumentWriterTests : IClassFixture _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlXmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); } diff --git a/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/JsonDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriterTests.cs similarity index 93% rename from source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/JsonDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriterTests.cs index fe2e9d0c81..bcbda67f27 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/JsonDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierJsonDocumentWriterTests.cs @@ -34,19 +34,19 @@ namespace Tests.Infrastructure.OutgoingMessages.RejectRequestChangeOfSupplier; -public class JsonDocumentWriterTests +public class RejectRequestChangeOfSupplierJsonDocumentWriterTests { private const string DocumentType = "RejectRequestChangeOfSupplier_MarketDocument"; - private readonly RejectRequestChangeOfSupplierJsonMessageWriter _messageWriter; + private readonly RejectRequestChangeOfSupplierJsonDocumentWriter _documentWriter; private readonly ISystemDateTimeProvider _systemDateTimeProvider; private readonly IMessageRecordParser _messageRecordParser; private readonly JsonSchemaProvider _schemaProvider; - public JsonDocumentWriterTests() + public RejectRequestChangeOfSupplierJsonDocumentWriterTests() { _systemDateTimeProvider = new SystemDateTimeProvider(); _messageRecordParser = new MessageRecordParser(new Serializer()); - _messageWriter = new RejectRequestChangeOfSupplierJsonMessageWriter(_messageRecordParser); + _documentWriter = new RejectRequestChangeOfSupplierJsonDocumentWriter(_messageRecordParser); _schemaProvider = new JsonSchemaProvider(new CimJsonSchemas()); } @@ -69,7 +69,7 @@ public async Task Document_is_valid() }), }; - var message = await _messageWriter.WriteAsync( + var message = await _documentWriter.WriteAsync( header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); diff --git a/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierDocumentWriterTests.cs b/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriterTests.cs similarity index 88% rename from source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierDocumentWriterTests.cs rename to source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriterTests.cs index 2d996cdf71..b874aeef57 100644 --- a/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierDocumentWriterTests.cs +++ b/source/Tests/Infrastructure/OutgoingMessages/RejectRequestChangeOfSupplier/RejectRequestChangeOfSupplierXmlDocumentWriterTests.cs @@ -33,16 +33,16 @@ namespace Tests.Infrastructure.OutgoingMessages.RejectRequestChangeOfSupplier; -public class RejectRequestChangeOfSupplierDocumentWriterTests +public class RejectRequestChangeOfSupplierXmlDocumentWriterTests { - private readonly RejectRequestChangeOfSupplierXmlMessageWriter _xmlMessageWriter; + private readonly RejectRequestChangeOfSupplierXmlDocumentWriter _xmlDocumentWriter; private readonly IMessageRecordParser _messageRecordParser; private ISchemaProvider? _schemaProvider; - public RejectRequestChangeOfSupplierDocumentWriterTests() + public RejectRequestChangeOfSupplierXmlDocumentWriterTests() { _messageRecordParser = new MessageRecordParser(new Serializer()); - _xmlMessageWriter = new RejectRequestChangeOfSupplierXmlMessageWriter(_messageRecordParser); + _xmlDocumentWriter = new RejectRequestChangeOfSupplierXmlDocumentWriter(_messageRecordParser); } [Fact] @@ -64,7 +64,7 @@ public async Task Document_is_valid() }), }; - var message = await _xmlMessageWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); + var message = await _xmlDocumentWriter.WriteAsync(header, marketActivityRecords.Select(record => _messageRecordParser.From(record)).ToList()).ConfigureAwait(false); await AssertMessage(message, header, marketActivityRecords).ConfigureAwait(false); }