From: chleun.moon Date: Wed, 23 May 2018 01:26:55 +0000 (+0900) Subject: [Network][Manual][Non-ACR] EthernetCableStateChanged event cannot throw NotSupportedE... X-Git-Tag: public_m1_final~12 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F37%2F179837%2F2;p=test%2Ftct%2Fcsharp%2Fapi.git [Network][Manual][Non-ACR] EthernetCableStateChanged event cannot throw NotSupportedException Change-Id: I882ef547d741e7c193125053b5bd45e717f221d7 Signed-off-by: Cheoleun Moon --- diff --git a/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSConnectionManager.cs b/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSConnectionManager.cs old mode 100755 new mode 100644 index 1e0aa25..fbe0c5a --- a/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSConnectionManager.cs +++ b/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSConnectionManager.cs @@ -21,8 +21,8 @@ using NUnit.Framework.TUnit; using Xamarin.Forms; using Tizen.System; using Tizen.Network.Connection; -using networkUtils; - +using networkUtils; + namespace Tizen.Network.Connection.Tests { [TestFixture] @@ -70,6 +70,11 @@ namespace Tizen.Network.Connection.Tests await ManualTest.WaitForConfirm(); return; } + if (isEthernetSupported == false) + { + Assert.IsTrue(true, "Cannot test cases about EthernetCableStateChanged events"); + return; + } try { ConnectionManager.EthernetCableStateChanged += EventHandlerEthernetCableStateChanged; @@ -77,14 +82,6 @@ namespace Tizen.Network.Connection.Tests ConnectionManager.EthernetCableStateChanged -= EventHandlerEthernetCableStateChanged; Assert.IsTrue(_flag, "EthernetCableStateChanged event is not occurred"); } - catch (NotSupportedException) - { - Assert.IsTrue(isEthernetSupported == false, "Invalid NotSupportedException"); - } - catch (TypeInitializationException e) - { - Assert.IsTrue(isEthernetSupported == false && e.InnerException.GetType() == typeof(NotSupportedException), "Invalid NotSupportedException or TypeInitializationException"); - } catch (Exception ex) { Assert.True(false, "Exception occurs. Msg : " + ex.ToString()); diff --git a/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSEthernetCableStateEventArgs.cs b/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSEthernetCableStateEventArgs.cs old mode 100755 new mode 100644 index 2cb8584..13715da --- a/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSEthernetCableStateEventArgs.cs +++ b/tct-suite-vs/Tizen.Network.Manual.Tests/testcase/TSEthernetCableStateEventArgs.cs @@ -21,8 +21,8 @@ using NUnit.Framework.TUnit; using Xamarin.Forms; using Tizen.System; using Tizen.Network.Connection; -using networkUtils; - +using networkUtils; + namespace Tizen.Network.Connection.Tests { [TestFixture] @@ -78,6 +78,11 @@ namespace Tizen.Network.Connection.Tests await ManualTest.WaitForConfirm(); return; } + if (isEthernetSupported == false) + { + Assert.IsTrue(true, "Cannot test cases about EthernetCableStateChanged events"); + return; + } try { ConnectionManager.EthernetCableStateChanged += EventHandlerEthernetCableStateChanged; @@ -86,14 +91,6 @@ namespace Tizen.Network.Connection.Tests Assert.IsTrue(_state == EthernetCableState.Detached, "Invalid EthernetCableState"); ConnectionManager.EthernetCableStateChanged -= EventHandlerEthernetCableStateChanged; } - catch (NotSupportedException) - { - Assert.IsTrue(isEthernetSupported == false, "Invalid NotSupportedException"); - } - catch (TypeInitializationException e) - { - Assert.IsTrue(isEthernetSupported == false && e.InnerException.GetType() == typeof(NotSupportedException), "Invalid NotSupportedException or TypeInitializationException"); - } catch (Exception ex) { Assert.True(false, "Exception occurs. Msg : " + ex.ToString());