Skip to content

Commit

Permalink
Upgrade some nugets
Browse files Browse the repository at this point in the history
Small cleanups
  • Loading branch information
monoman committed May 23, 2024
1 parent ad08440 commit 86c7d93
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@
<Target Name="TagSources" />
<Target Name="NugetOrg" />
<ItemGroup>
<PackageReference Include="NUnit" Version="4.0.1" />
<PackageReference Include="NUnit.Analyzers" Version="4.0.1">
<PackageReference Include="NUnit" Version="4.1.0" />
<PackageReference Include="NUnit.Analyzers" Version="4.2.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
</PackageReference>
<PackageReference Include="NUnit3TestAdapter" Version="4.5.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.9.0" />
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.10.0" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\InterlockLedger.Commons\InterlockLedger.Commons.csproj" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,4 @@ private static void AssertLimitedRange(LimitedRange lr, string text, bool isInva
Assert.That(lr.InvalidityCause, Is.EqualTo(cause).IgnoreCase);
TestContext.WriteLine(lr.ToString());
}


}
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,4 @@ public void BidirectionalJsonOfPageOfT() {
var resultPage = JsonSerializer.Deserialize<PageOf<LimitedRange>>(json);
Assert.That(resultPage, Is.EqualTo(page));
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -45,11 +45,11 @@ public override DateOnly Read(ref Utf8JsonReader reader, Type typeToConvert, Jso
if (typeToConvert == typeof(DateOnly)) {
string? s = reader.GetString();
if (s is not null)
return DateOnly.ParseExact(s, new string[] { _format, "yyyyMMdd", "dd'-'MMM'-'yy" }, CultureInfo.InvariantCulture);
return DateOnly.ParseExact(s, [_format, "yyyyMMdd", "dd'-'MMM'-'yy"], CultureInfo.InvariantCulture);
}

throw new InvalidDataException("Not a valid date");
}

public override void Write(Utf8JsonWriter writer, DateOnly value, JsonSerializerOptions options) =>
writer.Required().WriteStringValue(value.ToString(_format, CultureInfo.InvariantCulture));
}

0 comments on commit 86c7d93

Please sign in to comment.