[MediaController][Non-ACR] Fix deadlock issue 93/255993/1
authorHaesu Gwon <haesu.gwon@samsung.com>
Fri, 26 Mar 2021 07:39:03 +0000 (16:39 +0900)
committerHaesu Gwon <haesu.gwon@samsung.com>
Fri, 26 Mar 2021 07:39:03 +0000 (16:39 +0900)
Change-Id: I5b8685bd43dc3bc09b215b333f437f49de67164a

tct-suite-vs/Tizen.MediaController.Tests/testcase/TSMediaControlServer.cs
tct-suite-vs/Tizen.MediaController.Tests/testcase/TSMediaController.cs

index f8d1f41..ffba1dc 100644 (file)
@@ -606,11 +606,8 @@ namespace Tizen.Multimedia.Remoting.Tests
                     {
                         MediaControlServer.CustomCommandReceived += eventHandler;
 
-                        await Task.Run(() =>
-                        {
-                            var serverResult = controller.RequestCommandAsync(new CustomCommand("Custom"));
-                            Assert.AreEqual(serverResult.Result.result, (int)result, "Should be same value");
-                        });
+                        var serverResult = await controller.RequestCommandAsync(new CustomCommand("Custom"));
+                        Assert.AreEqual(serverResult.result, (int)result, "Should be same value");
                     }
                     finally
                     {
@@ -679,11 +676,8 @@ namespace Tizen.Multimedia.Remoting.Tests
                     {
                         MediaControlServer.CustomCommandReceived += eventHandler;
 
-                        await Task.Run(() =>
-                        {
-                            var serverResult = controller.RequestCommandAsync(new CustomCommand("Custom"));
-                            Assert.AreEqual(serverResult.Result.result, (int)result, "Should be same value");
-                        });
+                        var serverResult = await controller.RequestCommandAsync(new CustomCommand("Custom"));
+                        Assert.AreEqual(serverResult.result, (int)result, "Should be same value");
                     }
                     finally
                     {
index 56247ae..cc9efb4 100644 (file)
@@ -1251,13 +1251,10 @@ namespace Tizen.Multimedia.Remoting.Tests
                 {
                     _controller.CustomCommandReceived += eventHandler;
 
-                    await Task.Run(() =>
-                    {
-                        var clientResult = MediaControlServer.RequestCommandAsync(new CustomCommand("CustomCommand"),
-                            Application.Current.ApplicationInfo.ApplicationId);
+                    var clientResult = await MediaControlServer.RequestCommandAsync(new CustomCommand("CustomCommand"),
+                        Application.Current.ApplicationInfo.ApplicationId);
 
-                        Assert.AreEqual(clientResult.Result.result, (int)result, "Should be same value");
-                    });
+                    Assert.AreEqual(clientResult.result, (int)result, "Should be same value");
                 }
                 finally
                 {
@@ -1321,13 +1318,10 @@ namespace Tizen.Multimedia.Remoting.Tests
                 {
                     _controller.CustomCommandReceived += eventHandler;
 
-                    await Task.Run(() =>
-                    {
-                        var clientResult = MediaControlServer.RequestCommandAsync(new CustomCommand("CustomCommand"),
-                            Application.Current.ApplicationInfo.ApplicationId);
+                    var clientResult = await MediaControlServer.RequestCommandAsync(new CustomCommand("CustomCommand"),
+                        Application.Current.ApplicationInfo.ApplicationId);
 
-                        Assert.AreEqual(clientResult.Result.result, (int)result, "Should be same value");
-                    });
+                    Assert.AreEqual(clientResult.result, (int)result, "Should be same value");
                 }
                 finally
                 {