Skip to content

Commit 9f80241

Browse files
egillinkdotnet
andauthored
Release of new minor version v1.30 (#1506)
* Set version to '1.30-preview' * fix: Replace Tokens in docfx.json for release information (#1496) * fix: Add net7.0 for devcontainers * fix: Bunit browser file exc (#1504) * chore: Align package versions * fix: BunitBrowserFile throws when filesize too big * chore: Fix CVE in System.Text.Json for production code * docs: Added changelog entry * Set version to '1.30' --------- Co-authored-by: Egil Hansen <[email protected]> Co-authored-by: Steven Giesel <[email protected]>
2 parents be59e05 + 7ce3d34 commit 9f80241

File tree

22 files changed

+73
-23
lines changed

22 files changed

+73
-23
lines changed

.devcontainer/devcontainer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"features": {
88
"ghcr.io/devcontainers/features/dotnet:2": {
99
"version": "latest",
10-
"additionalVersions": "6.0,5.0,3.1"
10+
"additionalVersions": "7.0,6.0,5.0,3.1"
1111
}
1212
},
1313

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -222,7 +222,7 @@ jobs:
222222
- name: 🍥 Replace tokens in files
223223
uses: cschleiden/replace-tokens@v1
224224
with:
225-
files: '["docs/site/*.md", "docs/**/*.md", "docs/**/*.tmpl.partial", "*.csproj", "**/*.csproj", "src/Directory.Build.props"]'
225+
files: '["docs/site/*.md", "docs/**/*.md", "docs/**/*.tmpl.partial", "*.csproj", "**/*.csproj", "src/Directory.Build.props", "docs/site/docfx.json"]'
226226
env:
227227
RELEASE_VERSION: ${{ env.NBGV_SimpleVersion }}${{ env.NBGV_PrereleaseVersion }}
228228
RELEASE_NOTES: ${{ steps.changelog_reader.outputs.changes }}

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ All notable changes to **bUnit** will be documented in this file. The project ad
66

77
## [Unreleased]
88

9+
### Fixed
10+
11+
- `UploadFile` doesn't throw an exception when the file size exceeds the maximum allowed size. Reported by [@MorneZaayman](https://github.com/MorneZaayman) in [#1503](https://github.com/bUnit-dev/bUnit/issues/1503). Fixed by [@linkdotnet](https://github.com/linkdotnet).
12+
913
## [1.29.5] - 2024-07-05
1014

1115
### Fixed

Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@
5252
<!-- Shared code analyzers used for all projects in the solution -->
5353
<ItemGroup Label="Code Analyzers">
5454
<PackageReference Include="AsyncFixer" Version="1.6.0" PrivateAssets="All" />
55-
<PackageReference Include="SonarAnalyzer.CSharp" Version="9.26.0.92422" PrivateAssets="All" />
55+
<PackageReference Include="SonarAnalyzer.CSharp" Version="9.29.0.95321" PrivateAssets="All" />
5656
</ItemGroup>
5757

5858
<ItemGroup Label="Implicit usings"

benchmark/bunit.benchmarks.assets/bunit.benchmarks.assets.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
</ItemGroup>
1313

1414
<ItemGroup>
15-
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="6.0.4" />
15+
<PackageReference Include="Microsoft.AspNetCore.Components.Web" Version="6.0.32" />
1616
</ItemGroup>
1717

1818
</Project>

docs/samples/tests/Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
</PropertyGroup>
1414

1515
<ItemGroup Condition="'$(TargetFramework)' == 'net6.0' OR '$(TargetFramework)' == 'net7.0' OR '$(TargetFramework)' == 'net8.0'">
16-
<PackageReference Include="System.Text.Json" Version="8.0.0" />
16+
<PackageReference Include="System.Text.Json" Version="8.0.4" />
1717
</ItemGroup>
1818

1919
<ItemGroup Condition="'$(TargetFramework)' == 'net9.0'">

docs/samples/tests/razor/bunit.docs.razor.samples.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
<PackageReference Include="Moq" Version="4.16.1" />
1010
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.0.0" />
1111
<PackageReference Include="NSubstitute" Version="4.2.2" />
12-
<PackageReference Include="xunit" Version="2.8.1" />
12+
<PackageReference Include="xunit" Version="2.9.0" />
1313
<!-- DO NOT UPGRADE TO versions > 2.4.5 as they do not support .net5 or older -->
1414
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
1515
<PrivateAssets>all</PrivateAssets>

docs/samples/tests/xunit/bunit.docs.xunit.samples.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111
<PackageReference Include="Moq" Version="4.16.1" />
1212
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.0.0" />
1313
<PackageReference Include="NSubstitute" Version="4.2.2" />
14-
<PackageReference Include="xunit" Version="2.8.1" />
14+
<PackageReference Include="xunit" Version="2.9.0" />
1515
<!-- DO NOT UPGRADE TO versions > 2.4.5 as they do not support .net5 or older -->
1616
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.5">
1717
<PrivateAssets>all</PrivateAssets>

src/bunit.template/template/Company.BlazorTests1.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
</ItemGroup>
2626

2727
<ItemGroup Condition="'$(testFramework_xunit)' == 'true'">
28-
<PackageReference Include="xunit" Version="2.8.1" />
28+
<PackageReference Include="xunit" Version="2.9.0" />
2929
<PackageReference Include="xunit.runner.visualstudio" Version="2.5.4">
3030
<PrivateAssets>all</PrivateAssets>
3131
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>

src/bunit.web/Extensions/InputFile/BUnitBrowserFile.cs

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,12 @@ public BUnitBrowserFile(
2727

2828
public Stream OpenReadStream(long maxAllowedSize = 512000, CancellationToken cancellationToken = default)
2929
{
30+
if (Size > maxAllowedSize)
31+
{
32+
throw new IOException($"Supplied file with size {Size} bytes exceeds the maximum of {maxAllowedSize} bytes.");
33+
}
34+
3035
return new MemoryStream(Content);
3136
}
3237
}
33-
#endif
38+
#endif

0 commit comments

Comments
 (0)