Skip to content

Commit 44ef47a

Browse files
authored
Merge pull request #2116 from aws/dev
Sync Dev and Master
2 parents 73c37bb + a25dadc commit 44ef47a

File tree

7 files changed

+77
-14
lines changed

7 files changed

+77
-14
lines changed

LambdaRuntimeDockerfiles/Images/net10/amd64/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Based on Docker image from: https://github.com/dotnet/dotnet-docker/
22

3-
ARG ASPNET_VERSION=10.0.0-preview.5.25277.114
4-
ARG ASPNET_SHA512=6E69A85F7E18B8EEBB5F99A7E8099DB2FA5DA34BCF078BECBB123C0863D4BE7B4252C7CFC6B21B9585F4F800C058A12CAE55EF2A63B9BEA886CA3D1D8A0EC113
3+
ARG ASPNET_VERSION=10.0.0-preview.6.25358.103
4+
ARG ASPNET_SHA512=15ccea434f5e33b4af872bda00d30d3fee4494113a1e5d7b1e8ce206ab0a2e09384fa5a223afdde4b94ea3b7e12b796c1a45138be833288bd68741ae843fb6c8
55

66
ARG LAMBDA_RUNTIME_NAME=dotnet10
77
ARG AMAZON_LINUX=public.ecr.aws/lambda/provided:al2023

LambdaRuntimeDockerfiles/Images/net10/arm64/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Based on Docker image from: https://github.com/dotnet/dotnet-docker/
22

3-
ARG ASPNET_VERSION=10.0.0-preview.5.25277.114
4-
ARG ASPNET_SHA512=AC99EBEC4E7ABD660A27317D37DA56AE1FA8E9EBDBF4A88FE5F9BE58E1F4D7E8F05BEC32D5E902C0FDD1E9D9E250CDB49448266682010E4CF7F4640F9699B9F1
3+
ARG ASPNET_VERSION=10.0.0-preview.6.25358.103
4+
ARG ASPNET_SHA512=88667d66d90aaba30649f84d10d057da7c0db479cdb36b76824dc8e0f02a44a6bf5d269d74daa0d6b78376f2dc66b60238558267555e2ced40cbd06aac745d6a
55

66
ARG LAMBDA_RUNTIME_NAME=dotnet10
77
ARG AMAZON_LINUX=public.ecr.aws/lambda/provided:al2023

LambdaRuntimeDockerfiles/Images/net9/amd64/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Based on Docker image from: https://github.com/dotnet/dotnet-docker/
22

3-
ARG ASPNET_VERSION=9.0.6
4-
ARG ASPNET_SHA512=54c122c4c6127ce7e0f0ad0479a101db1455484c9e5bffa8fdc0dd72d2db028be86861f331f2c7c1cb2eaee9a92e741e4e5da567795533e46af27e4e481c0451
3+
ARG ASPNET_VERSION=9.0.7
4+
ARG ASPNET_SHA512=b175d4d0578f9f5d735d59def3f44459462ef36b4bd07d9ca0ed9853bf42d90c7bace195ff264a9dcf6dd4d6d452c87059085146268fce3540ed58eaf39629eb
55

66
ARG LAMBDA_RUNTIME_NAME=dotnet9
77
ARG AMAZON_LINUX=public.ecr.aws/lambda/provided:al2023

LambdaRuntimeDockerfiles/Images/net9/arm64/Dockerfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# Based on Docker image from: https://github.com/dotnet/dotnet-docker/
22

3-
ARG ASPNET_VERSION=9.0.6
4-
ARG ASPNET_SHA512=8a7024bd144254f400c0758efd5c39854eba5d7e3187fbde2dc857cedd9012ae93aceeb1683bf6bf390cefba40c50f95cc3295a1a8eb83133a8e01b91289dfc5
3+
ARG ASPNET_VERSION=9.0.7
4+
ARG ASPNET_SHA512=79b28df2bc522d47bd0ea3f8b4aaa447102f92019d038670743fbbc1e6b31dd206499ff6dfc2d31623dedb64a9e2ca23608c7ea7225f1f071745de72c9f81bf4
55

66
ARG LAMBDA_RUNTIME_NAME=dotnet9
77
ARG AMAZON_LINUX=public.ecr.aws/lambda/provided:al2023

Tools/LambdaTestTool-v2/src/Amazon.Lambda.TestTool/Amazon.Lambda.TestTool.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,6 @@
2121
<PackageReadmeFile>README.md</PackageReadmeFile>
2222
</PropertyGroup>
2323

24-
<ItemGroup Condition="$(Configuration) == 'Release'">
25-
<None Include="$(OutputPath)\publish\wwwroot\" Pack="true" PackagePath="tools\net8.0\any\wwwroot" Visible="false" />
26-
</ItemGroup>
27-
2824
<ItemGroup>
2925
<PackageReference Include="Amazon.Lambda.SQSEvents" Version="2.2.0" />
3026
<PackageReference Include="AWSSDK.Extensions.NETCore.Setup" Version="4.0.0" />

Tools/LambdaTestTool-v2/tests/Amazon.Lambda.TestTool.UnitTests/PackagingTests.cs

Lines changed: 68 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,78 @@ public PackagingTests(ITestOutputHelper output)
1818
_workingDirectory = DirectoryHelpers.GetTempTestAppDirectory(solutionRoot);
1919
}
2020

21+
[Fact]
22+
public void VerifyPackageContentsHasStaticAssets()
23+
{
24+
var projectPath = Path.Combine(_workingDirectory, "Tools", "LambdaTestTool-v2", "src", "Amazon.Lambda.TestTool", "Amazon.Lambda.TestTool.csproj");
25+
_output.WriteLine("Packing TestTool...");
26+
var packProcess = new Process
27+
{
28+
StartInfo = new ProcessStartInfo
29+
{
30+
FileName = "dotnet",
31+
Arguments = $"pack -c Release --no-build --no-restore {projectPath}",
32+
RedirectStandardOutput = true,
33+
RedirectStandardError = true,
34+
UseShellExecute = false,
35+
CreateNoWindow = true,
36+
}
37+
};
38+
39+
packProcess.Start();
40+
string packOutput = packProcess.StandardOutput.ReadToEnd();
41+
string packError = packProcess.StandardError.ReadToEnd();
42+
packProcess.WaitForExit(int.MaxValue);
43+
44+
_output.WriteLine("Pack Output:");
45+
_output.WriteLine(packOutput);
46+
if (!string.IsNullOrEmpty(packError))
47+
{
48+
_output.WriteLine("Pack Errors:");
49+
_output.WriteLine(packError);
50+
}
51+
52+
Assert.Equal(0, packProcess.ExitCode);
53+
54+
var packageDir = Path.Combine(Path.GetDirectoryName(projectPath)!, "bin", "Release");
55+
_output.WriteLine($"Looking for package in: {packageDir}");
56+
57+
var packageFiles = Directory.GetFiles(packageDir, "*.nupkg", SearchOption.AllDirectories);
58+
Assert.True(packageFiles.Length > 0, $"No .nupkg files found in {packageDir}");
59+
60+
var packagePath = packageFiles[0];
61+
_output.WriteLine($"Found package: {packagePath}");
62+
63+
using var archive = ZipFile.OpenRead(packagePath);
64+
65+
// Get all files for this framework
66+
var frameworkFiles = archive.Entries
67+
.Where(e => e.FullName.StartsWith($"tools/net8.0/any/wwwroot"))
68+
.Select(e => e.FullName)
69+
.ToList();
70+
71+
// Verify essential files exist
72+
var essentialFiles = new[]
73+
{
74+
$"tools/net8.0/any/wwwroot/bootstrap-icons/",
75+
$"tools/net8.0/any/wwwroot/bootstrap/",
76+
$"tools/net8.0/any/wwwroot/_content/BlazorMonaco/"
77+
};
78+
79+
var missingFiles = essentialFiles.Where(f => !frameworkFiles.Any(x => x.StartsWith(f))).ToList();
80+
81+
if (missingFiles.Any())
82+
{
83+
Assert.Fail($"The following static assets are missing:\n" +
84+
string.Join("\n", missingFiles));
85+
}
86+
}
87+
2188
[Fact]
2289
public void VerifyPackageContentsHasRuntimeSupport()
2390
{
2491
var projectPath = Path.Combine(_workingDirectory, "Tools", "LambdaTestTool-v2", "src", "Amazon.Lambda.TestTool", "Amazon.Lambda.TestTool.csproj");
25-
var expectedFrameworks = new string[] { "net6.0", "net8.0", "net9.0" };
92+
var expectedFrameworks = new string[] { "net6.0", "net8.0", "net9.0", "net10.0" };
2693
_output.WriteLine("Packing TestTool...");
2794
var packProcess = new Process
2895
{

Tools/LambdaTestTool-v2/tests/Amazon.Lambda.TestTool.UnitTests/Utilities/DirectoryHelpers.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ private static void CopyDirectory(DirectoryInfo dir, string destDirName)
6363
File.SetAttributes(tempPath, FileAttributes.Normal);
6464
}
6565

66-
foreach (var subdir in dirs.Where(x => !x.Name.Equals(".git")))
66+
foreach (var subdir in dirs.Where(x => !x.Name.Equals(".git") && !x.Name.Equals(".vs")))
6767
{
6868
var tempPath = Path.Combine(destDirName, subdir.Name);
6969
var subDir = new DirectoryInfo(subdir.FullName);

0 commit comments

Comments
 (0)