6 writes to WaitForValueTcs
Aspire.Hosting (1)
Orchestrator\ParameterProcessor.cs (1)
43parameterResource.WaitForValueTcs = new(TaskCreationOptions.RunContinuationsAsynchronously);
Aspire.Hosting.Tests (5)
Orchestrator\ParameterProcessorTests.cs (5)
184param.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 273parameterWithMissingValue.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 368parameter.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 417param.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 458secretParam.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously);
60 references to WaitForValueTcs
Aspire.Hosting (5)
ApplicationModel\ParameterResource.cs (2)
87if (WaitForValueTcs is not null) 90return await WaitForValueTcs.Task.WaitAsync(cancellationToken).ConfigureAwait(false);
Orchestrator\ParameterProcessor.cs (3)
184parameterResource.WaitForValueTcs?.TrySetResult(value); 201parameterResource.WaitForValueTcs?.TrySetException(ex); 329parameter.WaitForValueTcs?.TrySetResult(inputValue);
Aspire.Hosting.Tests (55)
Orchestrator\ParameterProcessorTests.cs (55)
37Assert.NotNull(param.WaitForValueTcs); 38Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 40Assert.Equal(param.Value, await param.WaitForValueTcs.Task); 63Assert.NotNull(param.WaitForValueTcs); 64Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 66Assert.Equal(param.Value, await param.WaitForValueTcs.Task); 113Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 114Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 129Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 130Assert.True(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 131Assert.True(parameterWithMissingValue.WaitForValueTcs.Task.IsFaulted); 132Assert.IsType<MissingParameterValueException>(parameterWithMissingValue.WaitForValueTcs.Task.Exception?.InnerException); 147Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 148Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 162Assert.NotNull(parameterWithError.WaitForValueTcs); 163Assert.True(parameterWithError.WaitForValueTcs.Task.IsCompleted); 164Assert.True(parameterWithError.WaitForValueTcs.Task.IsFaulted); 165Assert.IsType<InvalidOperationException>(parameterWithError.WaitForValueTcs.Task.Exception?.InnerException); 242Assert.True(param1.WaitForValueTcs!.Task.IsCompletedSuccessfully); 243Assert.True(param2.WaitForValueTcs!.Task.IsCompletedSuccessfully); 244Assert.True(secretParam.WaitForValueTcs!.Task.IsCompletedSuccessfully); 245Assert.Equal("value1", await param1.WaitForValueTcs.Task); 246Assert.Equal("value2", await param2.WaitForValueTcs.Task); 247Assert.Equal("secretValue", await secretParam.WaitForValueTcs.Task); 290Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 291Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 504Assert.NotNull(explicitParameterResource.WaitForValueTcs); 505Assert.NotNull(referencedParameterResource.WaitForValueTcs); 506Assert.True(explicitParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 507Assert.True(referencedParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 508Assert.Equal("explicitValue", await explicitParameterResource.WaitForValueTcs.Task); 509Assert.Equal("referencedValue", await referencedParameterResource.WaitForValueTcs.Task); 548Assert.NotNull(explicitParameterResource.WaitForValueTcs); 549Assert.True(explicitParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 550Assert.Equal("explicitValue", await explicitParameterResource.WaitForValueTcs.Task); 574Assert.NotNull(parameterResource.WaitForValueTcs); 575Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 576Assert.Equal("envValue", await parameterResource.WaitForValueTcs.Task); 596Assert.NotNull(parameterResource.WaitForValueTcs); 597Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 598Assert.Equal("testValue", await parameterResource.WaitForValueTcs.Task); 618Assert.NotNull(parameterResource.WaitForValueTcs); 619Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 620Assert.Equal("testValue", await parameterResource.WaitForValueTcs.Task); 644Assert.NotNull(parameterResource.WaitForValueTcs); 645Assert.False(parameterResource.WaitForValueTcs.Task.IsCompleted); 678Assert.NotNull(param.WaitForValueTcs); 679Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 715Assert.NotNull(parameterResource.WaitForValueTcs); 716Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 755Assert.NotNull(parameterResource.WaitForValueTcs); 756Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 853Assert.NotNull(parameterWithGenerateDefault.WaitForValueTcs); 854Assert.True(parameterWithGenerateDefault.WaitForValueTcs.Task.IsCompletedSuccessfully); 855Assert.Equal("existingValue", await parameterWithGenerateDefault.WaitForValueTcs.Task);