public void GetInstalledAppsTest()
        {
            MsIotApiWrapper    msIotApiWrapper = new MsIotApiWrapper("127.0.0.1", "user", "password", new MockHttpMessageHandler());
            List <AppxPackage> installedApps   = msIotApiWrapper.GetInstalledApps();

            Assert.AreEqual(installedApps.Count, 4);
            Assert.AreEqual(installedApps[0].CanUninstall, true);
            Assert.AreEqual(installedApps[0].PackageFullName, "Microsoft.Windows.Cortana_1.8.12.15063_neutral_neutral_cw5n1h2txyewy");
            Assert.AreEqual(installedApps[0].PackageName, "Search");
            Assert.AreEqual(installedApps[0].PackageRelativeId, "Microsoft.Windows.Cortana_cw5n1h2txyewy!CortanaUI");
        }
        public void GetInstalledAppsTest_WrongCredentials()
        {
            MsIotApiWrapper    msIotApiWrapper = new MsIotApiWrapper("127.0.0.1", "user_", "password", new MockHttpMessageHandler());
            AggregateException exception       = Assert.Throws <AggregateException>(() => msIotApiWrapper.GetInstalledApps());

            Assert.That(exception.InnerException.Message.Contains("401"));

            msIotApiWrapper = new MsIotApiWrapper("127.0.0.1", "user", "_password", new MockHttpMessageHandler());
            exception       = Assert.Throws <AggregateException>(() => msIotApiWrapper.GetInstalledApps());
            Assert.That(exception.InnerException.Message.Contains("401"));
        }