diff --git a/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Contracts/RaiseIntentRequest.cs b/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Contracts/RaiseIntentRequest.cs
index d02040488..c2c14502a 100644
--- a/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Contracts/RaiseIntentRequest.cs
+++ b/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Contracts/RaiseIntentRequest.cs
@@ -38,11 +38,6 @@ internal sealed class RaiseIntentRequest
///
public string Intent { get; set; }
- ///
- /// Indicates that the client selected an instance or an app to start and resolve the raised intent.
- ///
- public bool Selected { get; set; }
-
///
/// Context for identifying more the specific app that should handle the raised intent.
///
diff --git a/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Fdc3DesktopAgent.cs b/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Fdc3DesktopAgent.cs
index dbee924af..77d467c87 100644
--- a/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Fdc3DesktopAgent.cs
+++ b/src/fdc3/dotnet/DesktopAgent/src/MorganStanley.ComposeUI.DesktopAgent/Fdc3DesktopAgent.cs
@@ -669,11 +669,6 @@ public async ValueTask> RaiseIntent(Raise
//else for consistency it will return a single element array containing the intentMetadata which is allowed by the request.
Func, IEnumerable>?> selector = (fdc3App, appIntents) =>
{
- //If the user selects an application from the AppDirectory instead of the its running instance
- if (request.Selected && appIntents.TryGetValue(request.Intent, out var result) && result.Apps.Any())
- {
- return null;
- }
if (fdc3App.Interop?.Intents?.ListensFor == null
|| !fdc3App.Interop.Intents.ListensFor.TryGetValue(request.Intent!, out var intentMetadata))
diff --git a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/EndToEndTests.cs b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/EndToEndTests.cs
index a312edb40..952b98849 100644
--- a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/EndToEndTests.cs
+++ b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/EndToEndTests.cs
@@ -460,7 +460,6 @@ public async Task RaiseIntentReturnsNoAppsFound()
MessageId = 2,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "noIntentShouldHandle",
- Selected = false,
Context = new Context(ContextTypes.Nothing)
};
@@ -509,7 +508,6 @@ public async Task RaiseIntentReturnsAppIntentWithOneExistingAppAndPublishesConte
MessageId = 2,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -575,7 +573,6 @@ public async Task StoreIntentResultReturnsSuccessfully()
MessageId = 2,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -708,7 +705,6 @@ public async Task GetIntentResultReturnsSuccessfully()
MessageId = 2,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -819,7 +815,6 @@ public async Task AddIntentListenerSubscribesWithExistingAppPerRaisedIntent()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
},
diff --git a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Fdc3DesktopAgentTests.cs b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Fdc3DesktopAgentTests.cs
index d9a8e1c59..295eb6057 100644
--- a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Fdc3DesktopAgentTests.cs
+++ b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Fdc3DesktopAgentTests.cs
@@ -258,7 +258,6 @@ public async Task GetIntentResult_returns()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -320,7 +319,6 @@ public async Task GetIntentResult_fails()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -395,7 +393,6 @@ public async Task StoreIntentResult_returns()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -448,7 +445,6 @@ public async Task AddIntentListener_subscribes()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -490,7 +486,6 @@ public async Task AddIntentListener_unsubscribes()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -540,7 +535,6 @@ public async Task RaiseIntent_returns_NoAppsFound()
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "noAppShouldReturn",
- Selected = false,
Context = new Context("context2")
};
@@ -557,7 +551,6 @@ public async Task RaiseIntent_calls_ResolverUI()
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context(ContextTypes.Nothing)
};
@@ -595,7 +588,6 @@ public async Task RaiseIntent_returns_one_running_app()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
diff --git a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Infrastructure/Internal/Fdc3DesktopAgentMessageRouterService.Tests.cs b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Infrastructure/Internal/Fdc3DesktopAgentMessageRouterService.Tests.cs
index 756a8772b..911ce193d 100644
--- a/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Infrastructure/Internal/Fdc3DesktopAgentMessageRouterService.Tests.cs
+++ b/src/fdc3/dotnet/DesktopAgent/test/MorganStanley.ComposeUI.DesktopAgent.Tests/Infrastructure/Internal/Fdc3DesktopAgentMessageRouterService.Tests.cs
@@ -125,7 +125,6 @@ public async Task HandleRaiseIntent_returns_IntentDeliveryFailed_error_as_no_int
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4" }
};
@@ -154,7 +153,6 @@ public async Task HandleRaiseIntent_returns_IntentDeliveryFailed_error_as_no_int
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom")
};
@@ -194,7 +192,6 @@ public async Task
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -253,7 +250,6 @@ public async Task
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -276,13 +272,18 @@ public async Task
[Fact]
public async Task HandleRaiseIntent_calls_ResolverUI_by_Context_filter()
{
+ await _fdc3.StartAsync(CancellationToken.None);
+
+ //TODO: should add some identifier to the query => "fdc3:" + instance.Manifest.Id
+ var origin = await _mockModuleLoader.Object.StartModule(new StartRequest("appId4"));
+ var originFdc3InstanceId = Fdc3InstanceIdRetriever.Get(origin);
+
var instanceId = Guid.NewGuid().ToString();
var raiseIntentRequest = new RaiseIntentRequest
{
MessageId = 1,
Fdc3InstanceId = instanceId,
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2")
};
@@ -299,7 +300,6 @@ public async Task HandleRaiseIntent_calls_ResolverUI_by_Context_filter_if_fdc3_n
MessageId = 1,
Fdc3InstanceId = instanceId,
Intent = "intentMetadata4",
- Selected = false,
Context = new Context(ContextTypes.Nothing)
};
@@ -315,7 +315,6 @@ public async Task HandleRaiseIntent_fails_as_no_apps_found_by_AppIdentifier()
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "testIntent",
- Selected = false,
Context = new Context("contextType"),
TargetAppIdentifier = new AppIdentifier { AppId = "noAppShouldReturn" }
};
@@ -333,7 +332,6 @@ public async Task HandleRaiseIntent_fails_as_no_apps_found_by_Context()
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("noAppShouldReturn")
};
@@ -350,7 +348,6 @@ public async Task HandleRaiseIntent_fails_as_no_apps_found_by_Intent()
MessageId = 1,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "noAppShouldReturn",
- Selected = false,
Context = new Context("context2")
};
@@ -412,7 +409,6 @@ public async Task HandleStoreIntentResult_succeeds_with_channel()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -462,7 +458,6 @@ public async Task HandleStoreIntentResult_succeeds_with_context()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = true,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -513,7 +508,6 @@ public async Task HandleStoreIntentResult_succeeds_with_voidResult()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -608,7 +602,6 @@ public async Task HandleGetIntentResult_fails_due_no_intent_found()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -671,7 +664,6 @@ public async Task HandleGetIntentResult_succeeds_with_context()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -734,7 +726,6 @@ public async Task HandleGetIntentResult_succeeds_with_channel()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -798,7 +789,6 @@ public async Task HandleGetIntentResult_succeeds_with_voidResult()
MessageId = int.MaxValue,
Fdc3InstanceId = Guid.NewGuid().ToString(),
Intent = "intentMetadata4",
- Selected = false,
Context = new Context("context2"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -887,7 +877,6 @@ public async Task HandleAddIntentListener_subscribes_to_existing_raised_intent()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
@@ -936,7 +925,6 @@ public async Task HandleAddIntentListener_subscribes()
MessageId = 1,
Fdc3InstanceId = originFdc3InstanceId,
Intent = "intentMetadataCustom",
- Selected = false,
Context = new Context("contextCustom"),
TargetAppIdentifier = new AppIdentifier { AppId = "appId4", InstanceId = targetFdc3InstanceId }
};
diff --git a/src/fdc3/js/composeui-fdc3/src/infrastructure/MessageRouterIntentsClient.ts b/src/fdc3/js/composeui-fdc3/src/infrastructure/MessageRouterIntentsClient.ts
index 80421c473..e6fb7b148 100644
--- a/src/fdc3/js/composeui-fdc3/src/infrastructure/MessageRouterIntentsClient.ts
+++ b/src/fdc3/js/composeui-fdc3/src/infrastructure/MessageRouterIntentsClient.ts
@@ -81,7 +81,7 @@ export class MessageRouterIntentsClient implements IntentsClient {
}
const messageId = Math.floor(Math.random() * 10000);
- const message = new Fdc3RaiseIntentRequest(messageId, window.composeui.fdc3.config!.instanceId!, intent, false, context, app);
+ const message = new Fdc3RaiseIntentRequest(messageId, window.composeui.fdc3.config!.instanceId!, intent, context, app);
const responseFromService = await this.messageRouterClient.invoke(ComposeUITopic.raiseIntent(), JSON.stringify(message));
if (!responseFromService) {
throw new Error(ComposeUIErrors.NoAnswerWasProvided);
diff --git a/src/fdc3/js/composeui-fdc3/src/infrastructure/messages/Fdc3RaiseIntentRequest.ts b/src/fdc3/js/composeui-fdc3/src/infrastructure/messages/Fdc3RaiseIntentRequest.ts
index d8c7947fd..81c1f7168 100644
--- a/src/fdc3/js/composeui-fdc3/src/infrastructure/messages/Fdc3RaiseIntentRequest.ts
+++ b/src/fdc3/js/composeui-fdc3/src/infrastructure/messages/Fdc3RaiseIntentRequest.ts
@@ -19,7 +19,6 @@ export class Fdc3RaiseIntentRequest {
public readonly messageId: number,
public readonly fdc3InstanceId: string,
public readonly intent: string,
- public readonly selected: boolean,
public readonly context: Context,
public readonly targetAppIdentifier?: AppIdentifier) {
}