Beispiel #1
0
        public void DualBoundaryPartAccessibleViaTwoBoundariesAtOnce(IContainer container)
        {
            BoundaryFactory root = container.GetExportedValue <BoundaryFactory>();
            PartImportingFromBothBoundaries dualBoundaryPart = root.DualBoundaryPartFactory.CreateExport().Value;

            Assert.NotNull(dualBoundaryPart);
            Assert.NotNull(dualBoundaryPart.Boundary1Value);
            Assert.NotNull(dualBoundaryPart.Boundary2Value);
        }
Beispiel #2
0
        private void BuildBoundary()
        {
            EncounterBoundaryRectGameLogic boundaryLogic = BoundaryFactory.CreateEncounterBoundary(this.parent, this.name, Guid.NewGuid().ToString(), this.width, this.length);

            if (this.position != null)
            {
                SetPosition(boundaryLogic.gameObject, this.position);
            }
        }
Beispiel #3
0
        public void DualBoundaryPartAccessibleViaOneBoundaryAtATime(IContainer container)
        {
            BoundaryFactory root          = container.GetExportedValue <BoundaryFactory>();
            Boundary1Part   boundary1Part = root.Boundary1Factory.CreateExport().Value;
            Boundary2Part   boundary2Part = boundary1Part.Boundary2Factory.CreateExport().Value;
            PartImportingFromBothBoundaries?dualBoundaryPart = boundary2Part.DualBoundaryPart;

            Assert.NotNull(dualBoundaryPart);
            Assert.Same(boundary2Part, dualBoundaryPart !.Boundary2Value);
            Assert.Same(boundary1Part, dualBoundaryPart.Boundary1Value);
        }