@@ -14,13 +14,15 @@ public sealed class ProcessTestFixture : IDisposable, IAsyncLifetime
14
14
{
15
15
private System . Diagnostics . Process ? _process ;
16
16
private HttpClient ? _httpClient ;
17
+ private string ? _daprAppIdd ;
17
18
18
19
/// <summary>
19
20
/// Called by xUnit before the test is run.
20
21
/// </summary>
21
22
/// <returns></returns>
22
23
public async Task InitializeAsync ( )
23
24
{
25
+ this . _daprAppIdd = Guid . NewGuid ( ) . ToString ( "n" ) ;
24
26
this . _httpClient = new HttpClient ( ) ;
25
27
await this . StartTestHostAsync ( ) ;
26
28
}
@@ -37,7 +39,7 @@ private async Task StartTestHostAsync()
37
39
var processStartInfo = new ProcessStartInfo
38
40
{
39
41
FileName = "dapr" ,
40
- Arguments = "run --app-id daprprocesstests --app-port 5200 --dapr-http-port 3500 -- dotnet run --urls http://localhost:5200" ,
42
+ Arguments = $ "run --app-id { this . _daprAppIdd ! } --app-port 5200 --dapr-http-port 3500 -- dotnet run --urls http://localhost:5200",
41
43
WorkingDirectory = workingDirectory ,
42
44
RedirectStandardOutput = false ,
43
45
RedirectStandardError = false ,
@@ -64,7 +66,7 @@ private async Task ShutdownTestHostAsync()
64
66
var processStartInfo = new ProcessStartInfo
65
67
{
66
68
FileName = "dapr" ,
67
- Arguments = "stop --app-id daprprocesstests " ,
69
+ Arguments = $ "stop --app-id { this . _daprAppIdd } ",
68
70
RedirectStandardOutput = false ,
69
71
RedirectStandardError = false ,
70
72
UseShellExecute = true ,
0 commit comments