6 writes to WaitForValueTcs
Aspire.Hosting (1)
Orchestrator\ParameterProcessor.cs (1)
43parameterResource.WaitForValueTcs = new(TaskCreationOptions.RunContinuationsAsynchronously);
Aspire.Hosting.Tests (5)
Orchestrator\ParameterProcessorTests.cs (5)
185param.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 274parameterWithMissingValue.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 369parameter.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 418param.WaitForValueTcs = new TaskCompletionSource<string>(TaskCreationOptions.RunContinuationsAsynchronously); 459secretParam.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); 331parameter.WaitForValueTcs?.TrySetResult(inputValue);
Aspire.Hosting.Tests (55)
Orchestrator\ParameterProcessorTests.cs (55)
38Assert.NotNull(param.WaitForValueTcs); 39Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 41Assert.Equal(param.Value, await param.WaitForValueTcs.Task); 64Assert.NotNull(param.WaitForValueTcs); 65Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 67Assert.Equal(param.Value, await param.WaitForValueTcs.Task); 114Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 115Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 130Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 131Assert.True(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 132Assert.True(parameterWithMissingValue.WaitForValueTcs.Task.IsFaulted); 133Assert.IsType<MissingParameterValueException>(parameterWithMissingValue.WaitForValueTcs.Task.Exception?.InnerException); 148Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 149Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 163Assert.NotNull(parameterWithError.WaitForValueTcs); 164Assert.True(parameterWithError.WaitForValueTcs.Task.IsCompleted); 165Assert.True(parameterWithError.WaitForValueTcs.Task.IsFaulted); 166Assert.IsType<InvalidOperationException>(parameterWithError.WaitForValueTcs.Task.Exception?.InnerException); 243Assert.True(param1.WaitForValueTcs!.Task.IsCompletedSuccessfully); 244Assert.True(param2.WaitForValueTcs!.Task.IsCompletedSuccessfully); 245Assert.True(secretParam.WaitForValueTcs!.Task.IsCompletedSuccessfully); 246Assert.Equal("value1", await param1.WaitForValueTcs.Task); 247Assert.Equal("value2", await param2.WaitForValueTcs.Task); 248Assert.Equal("secretValue", await secretParam.WaitForValueTcs.Task); 291Assert.NotNull(parameterWithMissingValue.WaitForValueTcs); 292Assert.False(parameterWithMissingValue.WaitForValueTcs.Task.IsCompleted); 505Assert.NotNull(explicitParameterResource.WaitForValueTcs); 506Assert.NotNull(referencedParameterResource.WaitForValueTcs); 507Assert.True(explicitParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 508Assert.True(referencedParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 509Assert.Equal("explicitValue", await explicitParameterResource.WaitForValueTcs.Task); 510Assert.Equal("referencedValue", await referencedParameterResource.WaitForValueTcs.Task); 549Assert.NotNull(explicitParameterResource.WaitForValueTcs); 550Assert.True(explicitParameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 551Assert.Equal("explicitValue", await explicitParameterResource.WaitForValueTcs.Task); 575Assert.NotNull(parameterResource.WaitForValueTcs); 576Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 577Assert.Equal("envValue", await parameterResource.WaitForValueTcs.Task); 597Assert.NotNull(parameterResource.WaitForValueTcs); 598Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 599Assert.Equal("testValue", await parameterResource.WaitForValueTcs.Task); 619Assert.NotNull(parameterResource.WaitForValueTcs); 620Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 621Assert.Equal("testValue", await parameterResource.WaitForValueTcs.Task); 645Assert.NotNull(parameterResource.WaitForValueTcs); 646Assert.False(parameterResource.WaitForValueTcs.Task.IsCompleted); 679Assert.NotNull(param.WaitForValueTcs); 680Assert.True(param.WaitForValueTcs.Task.IsCompletedSuccessfully); 716Assert.NotNull(parameterResource.WaitForValueTcs); 717Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 756Assert.NotNull(parameterResource.WaitForValueTcs); 757Assert.True(parameterResource.WaitForValueTcs.Task.IsCompletedSuccessfully); 853Assert.NotNull(parameterWithGenerateDefault.WaitForValueTcs); 854Assert.True(parameterWithGenerateDefault.WaitForValueTcs.Task.IsCompletedSuccessfully); 855Assert.Equal("existingValue", await parameterWithGenerateDefault.WaitForValueTcs.Task);