Beispiel #1
0
 public void BuildPascalUnitsWithReferences()
 {
     BuildPascalUnits();
     var resolver = new DeepReferenceResolver(Units);
     resolver.ResolveDependencies();
     _units.Clear();
     _units.AddRange(resolver.PascalUnits.SelectMany(x=>x.Value));
 }
        public void CanResolveSimpleSetOfDependencies()
        {
            var units = BuildUnits().ToList();
            var e = new DeepReferenceResolver(units);
            e.ResolveDependencies();

            var unit = units.Single(x => x.UnitName == TestConstants.WindowsUnit);
            Assert.AreEqual(1,unit.Units.Count);

            var depends = unit.DeepReferences;
            Assert.AreEqual(2,depends.Count());
        }
 public void CanResolveEmptySetDependencies()
 {
     var e = new DeepReferenceResolver(new List<PascalUnit>());
     e.ResolveDependencies();
 }
 public void CanCreate()
 {
     var e = new DeepReferenceResolver(new List<PascalUnit>());
 }