Skip to content

Commit

Permalink
Merge 5adba30 into e1a4430
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike-E-angelo authored Dec 3, 2020
2 parents e1a4430 + 5adba30 commit aec41bd
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,20 @@

namespace ExtendedXmlSerializer.ExtensionModel.Xml
{
sealed class MigrationsExtension : TypedTable<IEnumerable<Action<XElement>>>, ISerializerExtension
/// <summary>
/// This extension is meant for internal use, but has been exposed for extension authors who require access to it.
/// </summary>
/// <seealso href="https://github.com/ExtendedXmlSerializer/home/issues/483" />
public sealed class MigrationsExtension : TypedTable<IEnumerable<Action<XElement>>>, ISerializerExtension
{
/// <inheritdoc />
[UsedImplicitly]
public MigrationsExtension() : this(new Dictionary<TypeInfo, IEnumerable<Action<XElement>>>()) {}

/// <inheritdoc />
public MigrationsExtension(IDictionary<TypeInfo, IEnumerable<Action<XElement>>> store) : base(store) {}

/// <inheritdoc />
public IServiceRepository Get(IServiceRepository parameter) => parameter.Decorate<IContents>(Register);

IContents Register(IServiceProvider services, IContents contents)
Expand Down
19 changes: 19 additions & 0 deletions test/ExtendedXmlSerializer.Tests.ReportedIssues/Issue483Tests.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
using ExtendedXmlSerializer.Configuration;
using ExtendedXmlSerializer.ExtensionModel.Xml;
using FluentAssertions;
using Xunit;

namespace ExtendedXmlSerializer.Tests.ReportedIssues
{
public sealed class Issue483Tests
{
[Fact]
public void Verify()
{
new ConfigurationContainer().Type<Issue483Tests>().Root.With<MigrationsExtension>().Should().NotBeNull();

}


}
}

0 comments on commit aec41bd

Please sign in to comment.