-
Notifications
You must be signed in to change notification settings - Fork 739
Extract Aspire.Hosting.Dapr.Tests #5282
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 2 commits
8a34d1f
40fe58e
565a76e
3fc0b74
42914cb
8cde6b0
f4a3906
9e7c64a
2ace0a8
3559704
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -68,6 +68,7 @@ | |
| <ItemGroup> | ||
| <InternalsVisibleTo Include="Aspire.Hosting.Tests" /> | ||
| <InternalsVisibleTo Include="Aspire.Hosting.Containers.Tests" /> | ||
| <InternalsVisibleTo Include="Aspire.Hosting.Dapr.Tests" /> | ||
|
||
| </ItemGroup> | ||
|
|
||
| </Project> | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| <Project Sdk="Microsoft.NET.Sdk"> | ||
|
|
||
| <PropertyGroup> | ||
| <TargetFramework>$(NetCurrent)</TargetFramework> | ||
| </PropertyGroup> | ||
|
|
||
| <ItemGroup> | ||
| <ProjectReference Include="..\..\src\Aspire.Hosting.Dapr\Aspire.Hosting.Dapr.csproj" /> | ||
| <ProjectReference Include="..\..\src\Aspire.Hosting.Testing\Aspire.Hosting.Testing.csproj" /> | ||
sebastienros marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| <ProjectReference Include="..\Aspire.Hosting.Tests\Aspire.Hosting.Tests.csproj" /> | ||
| </ItemGroup> | ||
|
|
||
| </Project> | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,30 @@ | ||
| // Licensed to the .NET Foundation under one or more agreements. | ||
| // The .NET Foundation licenses this file to you under the MIT license. | ||
|
|
||
| using Aspire.Hosting.Tests.Schema; | ||
| using Xunit; | ||
|
|
||
| namespace Aspire.Hosting.Dapr.Tests; | ||
|
|
||
| public class DaprSchemaTests | ||
| { | ||
| [Fact] | ||
| public void ValidateWithDaprManifest() | ||
| { | ||
| new SchemaTests().ValidateApplicationSamples("DaprWithComponents", (IDistributedApplicationBuilder builder) => | ||
| { | ||
| var dapr = builder.AddDapr(dopts => | ||
| { | ||
| // Just to avoid dynamic discovery which will throw. | ||
| dopts.DaprPath = "notrealpath"; | ||
| }); | ||
| var state = dapr.AddDaprStateStore("daprstate"); | ||
| var pubsub = dapr.AddDaprPubSub("daprpubsub"); | ||
|
|
||
| builder.AddProject<Projects.ServiceA>("project") | ||
sebastienros marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| .WithDaprSidecar() | ||
| .WithReference(state) | ||
| .WithReference(pubsub); | ||
| }); | ||
| } | ||
| } | ||
Uh oh!
There was an error while loading. Please reload this page.