Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 26 additions & 3 deletions src/EdFi.Db.Deploy/DbUpLogger.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
// The Ed-Fi Alliance licenses this file to you under the Apache License, Version 2.0.
// See the LICENSE and NOTICES files in the project root for more information.

using System;
using DbUp.Engine.Output;
using EdFi.Db.Deploy.Helpers;
using log4net;
Expand All @@ -18,28 +19,50 @@ public DbUpLogger(ILog logger)
_logger = Preconditions.ThrowIfNull(logger, nameof(logger));
}

public void WriteInformation(string format, params object[] args)
public void LogInformation(string format, params object[] args)
{
Preconditions.ThrowIfNull(format, nameof(format));
Preconditions.ThrowIfNull(args, nameof(args));

_logger.Info(string.Format(format, args));
}

public void WriteError(string format, params object[] args)
public void LogError(string format, params object[] args)
{
Preconditions.ThrowIfNull(format, nameof(format));
Preconditions.ThrowIfNull(args, nameof(args));

_logger.Error(string.Format(format, args));
}

public void WriteWarning(string format, params object[] args)
public void LogWarning(string format, params object[] args)
{
Preconditions.ThrowIfNull(format, nameof(format));
Preconditions.ThrowIfNull(args, nameof(args));

_logger.Warn(string.Format(format, args));
}

public void LogTrace(string format, params object[] args)
{
LogInformation(format, args);
}

public void LogDebug(string format, params object[] args)
{
Preconditions.ThrowIfNull(format, nameof(format));
Preconditions.ThrowIfNull(args, nameof(args));

_logger.Debug(string.Format(format, args));
}

public void LogError(Exception exception, string format, params object[] args)
{
Preconditions.ThrowIfNull(exception, nameof(exception));
Preconditions.ThrowIfNull(format, nameof(format));
Preconditions.ThrowIfNull(args, nameof(args));

_logger.Error(string.Format(format, args), exception);
}
}
}
16 changes: 8 additions & 8 deletions src/EdFi.Db.Deploy/EdFi.Db.Deploy.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -22,15 +22,15 @@
</PropertyGroup>
<ItemGroup>
<PackageReference Include="CommandLineParser" Version="2.9.1" />
<PackageReference Include="Dapper" Version="2.1.28" />
<PackageReference Include="Dapper" Version="2.1.66" />
<PackageReference Include="Dapper.Contrib" Version="2.0.78" />
<PackageReference Include="dbup-core" Version="5.0.37" />
<PackageReference Include="dbup-postgresql" Version="5.0.40" />
<PackageReference Include="dbup-sqlserver" Version="5.0.39" />
<PackageReference Include="log4net" Version="2.0.15" />
<PackageReference Include="Microsoft.Data.SqlClient" Version="5.1.5" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
<PackageReference Include="Npgsql" Version="8.0.3" />
<PackageReference Include="dbup-core" Version="6.0.4" />
<PackageReference Include="dbup-postgresql" Version="6.0.3" />
<PackageReference Include="dbup-sqlserver" Version="6.0.0" />
<PackageReference Include="log4net" Version="3.2.0" />
<PackageReference Include="Microsoft.Data.SqlClient" Version="6.1.2" />
<PackageReference Include="Microsoft.Extensions.DependencyInjection" Version="8.0.1" />
<PackageReference Include="Npgsql" Version="9.0.4" />
</ItemGroup>
<ItemGroup>
<None Update="log4net.config">
Expand Down
12 changes: 6 additions & 6 deletions tests/EdFi.Db.Deploy.Tests/EdFi.Db.Deploy.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,15 @@
</PropertyGroup>

<ItemGroup>
<PackageReference Include="FakeItEasy" Version="8.1.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" />
<PackageReference Include="NUnit" Version="4.0.1" />
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0">
<PackageReference Include="FakeItEasy" Version="8.3.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.0.0" />
<PackageReference Include="NUnit" Version="4.4.0" />
<PackageReference Include="NUnit3TestAdapter" Version="5.2.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="Shouldly" Version="4.2.1" />
<PackageReference Include="TeamCity.VSTest.TestAdapter" Version="1.0.39" />
<PackageReference Include="Shouldly" Version="4.3.0" />
<PackageReference Include="TeamCity.VSTest.TestAdapter" Version="1.0.41" />
</ItemGroup>

<ItemGroup>
Expand Down
Loading