Skip to content

Commit 9de69eb

Browse files
committed
chore: add integration tests
1 parent 4a74be6 commit 9de69eb

27 files changed

Lines changed: 1477 additions & 67 deletions

AWS.AgentCore.slnx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,6 @@
1515
<Folder Name="/test/">
1616
<Project Path="test/AWS.AgentCore.UnitTests/AWS.AgentCore.UnitTests.csproj" />
1717
<Project Path="test/AWS.AgentCore.SourceGenerator.UnitTests/AWS.AgentCore.SourceGenerator.UnitTests.csproj" />
18+
<Project Path="test/AWS.AgentCore.IntegrationTests/AWS.AgentCore.IntegrationTests.csproj" />
1819
</Folder>
1920
</Solution>

buildtools/ci.buildspec.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ phases:
1313
build:
1414
commands:
1515
- dotnet build AWS.AgentCore.slnx -c Release
16-
- dotnet test AWS.AgentCore.slnx -c Release --no-build --logger trx --results-directory ./testresults
16+
- dotnet test AWS.AgentCore.slnx -c Release --no-build --logger trx --logger "console;verbosity=detailed" --results-directory ./testresults
1717
reports:
1818
aws-dotnet-ai-tests:
1919
file-format: VisualStudioTrx
Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,4 @@
1-
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS base
2-
USER $APP_UID
3-
WORKDIR /app
4-
EXPOSE 8080
5-
EXPOSE 8081
6-
7-
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
1+
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:10.0 AS build
82
ARG BUILD_CONFIGURATION=Release
93
WORKDIR /src
104
COPY ["sampleapps/AnnotationsSample/AnnotationsSample.csproj", "sampleapps/AnnotationsSample/"]
@@ -13,14 +7,11 @@ COPY ["src/AWS.AgentCore.SourceGenerator/AWS.AgentCore.SourceGenerator.csproj",
137
RUN dotnet restore "sampleapps/AnnotationsSample/AnnotationsSample.csproj"
148
COPY . .
159
WORKDIR "/src/sampleapps/AnnotationsSample"
16-
RUN dotnet build "./AnnotationsSample.csproj" -c $BUILD_CONFIGURATION -o /app/build
17-
18-
FROM build AS publish
19-
ARG BUILD_CONFIGURATION=Release
2010
RUN dotnet publish "./AnnotationsSample.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
2111

22-
FROM base AS final
12+
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS final
13+
USER $APP_UID
2314
WORKDIR /app
24-
COPY --from=publish /app/publish .
15+
EXPOSE 8080
16+
COPY --from=build /app/publish .
2517
ENTRYPOINT ["dotnet", "AnnotationsSample.dll"]
26-

sampleapps/AnnotationsSample/Startup.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public void ConfigureServices(WebApplicationBuilder builder)
1414
{
1515
builder.AddAgentCore(options =>
1616
{
17-
options.ModelId = "global.anthropic.claude-sonnet-4-20250514-v1:0";
17+
options.ModelId = "global.anthropic.claude-opus-4-7";
1818
});
1919
}
2020
}
Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,4 @@
1-
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS base
2-
USER $APP_UID
3-
WORKDIR /app
4-
EXPOSE 8080
5-
EXPOSE 8081
6-
7-
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
1+
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:10.0 AS build
82
ARG BUILD_CONFIGURATION=Release
93
WORKDIR /src
104
COPY ["sampleapps/AnnotationsStreamingAgent/AnnotationsStreamingAgent.csproj", "sampleapps/AnnotationsStreamingAgent/"]
@@ -13,14 +7,11 @@ COPY ["src/AWS.AgentCore.SourceGenerator/AWS.AgentCore.SourceGenerator.csproj",
137
RUN dotnet restore "sampleapps/AnnotationsStreamingAgent/AnnotationsStreamingAgent.csproj"
148
COPY . .
159
WORKDIR "/src/sampleapps/AnnotationsStreamingAgent"
16-
RUN dotnet build "./AnnotationsStreamingAgent.csproj" -c $BUILD_CONFIGURATION -o /app/build
17-
18-
FROM build AS publish
19-
ARG BUILD_CONFIGURATION=Release
2010
RUN dotnet publish "./AnnotationsStreamingAgent.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
2111

22-
FROM base AS final
12+
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS final
13+
USER $APP_UID
2314
WORKDIR /app
24-
COPY --from=publish /app/publish .
15+
EXPOSE 8080
16+
COPY --from=build /app/publish .
2517
ENTRYPOINT ["dotnet", "AnnotationsStreamingAgent.dll"]
26-

sampleapps/AnnotationsStreamingAgent/Startup.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public void ConfigureServices(WebApplicationBuilder builder)
1414
{
1515
builder.AddAgentCore(options =>
1616
{
17-
options.ModelId = "global.anthropic.claude-sonnet-4-20250514-v1:0";
17+
options.ModelId = "global.anthropic.claude-opus-4-7";
1818
});
1919
}
2020
}
Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,4 @@
1-
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS base
2-
USER $APP_UID
3-
WORKDIR /app
4-
EXPOSE 8080
5-
EXPOSE 8081
6-
7-
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
1+
FROM --platform=$BUILDPLATFORM mcr.microsoft.com/dotnet/sdk:10.0 AS build
82
ARG BUILD_CONFIGURATION=Release
93
WORKDIR /src
104
COPY ["sampleapps/MicrosoftAgentFrameworkSample/MicrosoftAgentFrameworkSample.csproj", "sampleapps/MicrosoftAgentFrameworkSample/"]
@@ -13,14 +7,11 @@ COPY ["src/AWS.AgentCore.SourceGenerator/AWS.AgentCore.SourceGenerator.csproj",
137
RUN dotnet restore "sampleapps/MicrosoftAgentFrameworkSample/MicrosoftAgentFrameworkSample.csproj"
148
COPY . .
159
WORKDIR "/src/sampleapps/MicrosoftAgentFrameworkSample"
16-
RUN dotnet build "./MicrosoftAgentFrameworkSample.csproj" -c $BUILD_CONFIGURATION -o /app/build
17-
18-
FROM build AS publish
19-
ARG BUILD_CONFIGURATION=Release
2010
RUN dotnet publish "./MicrosoftAgentFrameworkSample.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
2111

22-
FROM base AS final
12+
FROM mcr.microsoft.com/dotnet/aspnet:10.0 AS final
13+
USER $APP_UID
2314
WORKDIR /app
24-
COPY --from=publish /app/publish .
15+
EXPOSE 8080
16+
COPY --from=build /app/publish .
2517
ENTRYPOINT ["dotnet", "MicrosoftAgentFrameworkSample.dll"]
26-

sampleapps/MicrosoftAgentFrameworkSample/Program.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@
1111

1212
builder.AddAgentCore(options =>
1313
{
14-
options.ModelId = "global.anthropic.claude-sonnet-4-20250514-v1:0";
14+
options.ModelId = "global.anthropic.claude-opus-4-7";
1515
});
1616

1717
var app = builder.Build();

sampleapps/NativeAotAnnotations/Dockerfile

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
FROM mcr.microsoft.com/dotnet/sdk:10.0 AS build
1+
FROM mcr.microsoft.com/dotnet/sdk:10.0-aot AS build
22
ARG BUILD_CONFIGURATION=Release
3-
RUN apt-get update && apt-get install -y clang zlib1g-dev && rm -rf /var/lib/apt/lists/*
43
WORKDIR /src
54
COPY ["sampleapps/NativeAotAnnotations/NativeAotAnnotations.csproj", "sampleapps/NativeAotAnnotations/"]
65
COPY ["src/AWS.AgentCore/AWS.AgentCore.csproj", "src/AWS.AgentCore/"]

sampleapps/NativeAotAnnotations/Startup.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ public void ConfigureServices(WebApplicationBuilder builder)
1414
{
1515
builder.AddAgentCore(options =>
1616
{
17-
options.ModelId = "global.anthropic.claude-sonnet-4-20250514-v1:0";
17+
options.ModelId = "global.anthropic.claude-opus-4-7";
1818
});
1919
}
2020
}

0 commit comments

Comments
 (0)