Ejemplo n.º 1
0
        public void TestComObjectCollector()
        {
            if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
            {
                Setup();

                var FirstRunId = "TestComObjectCollector-1";

                var coc = new ComObjectCollector(FirstRunId);
                coc.Execute();

                List <RawCollectResult> collectResults = DatabaseManager.GetResultsByRunid(FirstRunId);

                List <ComObject> comObjects = new List <ComObject>();

                foreach (var collectResult in collectResults)
                {
                    comObjects.Add((ComObject)(collectResult.DeserializedObject));
                }

                Assert.IsTrue(comObjects.Where(x => x.x86_Binary != null).Count() > 0);

                TearDown();
            }
        }
        public void TestComObjectCollector()
        {
            if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
            {
                var coc = new ComObjectCollector(new CollectCommandOptions());
                coc.Execute();

                Assert.IsTrue(coc.Results.Any(x => x is ComObject y && y.x86_Binary != null));
            }
        }