public void Should_be_possible_to_collect_a_metabase_object_with_set()
        {
            var metabaseProber = new MetabaseProber();
            ProberBehaviorCreator
                .CreateBehaviorForNormalFlowExecution(
                    metabaseProber,
                    new ItemType[] { new metabase_item() },
                    new CollectedItem[] { ProbeHelper.CreateFakeCollectedItem(new metabase_item()) }
            );

            var probeResult = metabaseProber.Execute(
                FakeContext, 
                FakeTargetInfo, 
                GetFakeCollectInfo("6002", "definitionsSimple.xml", "system_characteristics_with_sets.xml"));

            Assert.IsNotNull(probeResult);
            Assert.IsFalse(probeResult.HasErrors());
            Assert.IsNotNull(probeResult.CollectedObjects);
            Assert.AreEqual(1, probeResult.CollectedObjects.Count());
            var collectedObject = probeResult.CollectedObjects.First();
            Assert.AreEqual("oval:modulo:obj:6002", collectedObject.ObjectType.id);
            Assert.AreEqual(2, collectedObject.SystemData.Count);
            Assert.AreEqual("2000", collectedObject.SystemData.ElementAt(0).id);
            Assert.AreEqual("2001", collectedObject.SystemData.ElementAt(1).id);
        }
        public void Should_be_possible_to_handle_an_error_during_itemtypes_generation()
        {
            var metabaseProber = new MetabaseProber();
            ProberBehaviorCreator.CreateBehaviorWithExceptionThrowing(metabaseProber);

            var probeResult = metabaseProber.Execute(FakeContext, FakeTargetInfo, GetFakeCollectInfo("6001"));

            DoAssertForExecutionWithErrors(probeResult, typeof(metabase_item));
        }
        public void Should_be_possible_to_collect_an_metabase_object()
        {
            var metabaseProber = new MetabaseProber();
            ProberBehaviorCreator
                .CreateBehaviorForNormalFlowExecution(
                    metabaseProber,
                    new ItemType[] { new metabase_item() },
                    new CollectedItem[] { ProbeHelper.CreateFakeCollectedItem(new metabase_item()) }
            );

            var probeResult = metabaseProber.Execute(FakeContext, FakeTargetInfo, GetFakeCollectInfo("6000"));

            DoAssertForSingleCollectedObject(probeResult, typeof(metabase_item));
        }