[AudioManager][Non-ACR][Add negative testcases for Add[Remove]DeviceForStreamRouting] 68/215168/1
authorSangchul Lee <sc11.lee@samsung.com>
Wed, 2 Oct 2019 06:43:01 +0000 (15:43 +0900)
committerSangchul Lee <sc11.lee@samsung.com>
Wed, 2 Oct 2019 06:43:01 +0000 (15:43 +0900)
Change-Id: I6b61b599b0ea8ca7e3243a97e4657372b6e36212
Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
tct-suite-vs/Tizen.Multimedia.Tests/testcase/AudioManager/TSAudioStreamPolicy.cs

index 9d83ef056a8c121e9f4e2e6c95bb2c2d18da93a7..0feca3895049f8d684f6a5546ac20d025727622d 100644 (file)
@@ -433,6 +433,22 @@ namespace Tizen.Multimedia.Tests
             }
         }
 
+        [Test]
+        [Category("P2")]
+        [Description("Throws if device is null")]
+        [Property("SPEC", "Tizen.Multimedia.AudioStreamPolicy.AddDeviceForStreamRouting M")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "MEX")]
+        [Property("AUTHOR", "Sangchul Lee, sc11.lee@samsung.com")]
+        public void AddDeviceForStreamRouting_ARGUMENT_NULL_EXCEPTION()
+        {
+            using (AudioStreamPolicy asp = new AudioStreamPolicy(AudioStreamType.Voip))
+            {
+                Assert.That(() => asp.AddDeviceForStreamRouting(null),
+                    Throws.TypeOf<ArgumentNullException>());
+            }
+        }
+
         [Test]
         [Category("P2")]
         [Description("Throws if stream type is not supported for the method")]
@@ -501,6 +517,22 @@ namespace Tizen.Multimedia.Tests
             }
         }
 
+        [Test]
+        [Category("P2")]
+        [Description("Throws if device is null")]
+        [Property("SPEC", "Tizen.Multimedia.AudioStreamPolicy.RemoveDeviceForStreamRouting M")]
+        [Property("SPEC_URL", "-")]
+        [Property("CRITERIA", "MEX")]
+        [Property("AUTHOR", "Sangchul Lee, sc11.lee@samsung.com")]
+        public void RemoveDeviceForStreamRouting_ARGUMENT_NULL_EXCEPTION()
+        {
+            using (AudioStreamPolicy asp = new AudioStreamPolicy(AudioStreamType.Voip))
+            {
+                Assert.That(() => asp.RemoveDeviceForStreamRouting(null),
+                    Throws.TypeOf<ArgumentNullException>());
+            }
+        }
+
         [Test]
         [Category("P1")]
         [Description("Sets and gets the preferred output device.")]