public void SetUp()
        {
            _transponderReceiver = Substitute.For <ITransponderReceiver>();
            _trackTransmitter    = new TrackTransmitter();
            _dateTimeBuilder     = new DateTimeBuilder();

            _trackObjectifier = new TrackObjectifier(_dateTimeBuilder);

            _trackReciever = new TrackReciever(_transponderReceiver,
                                               _trackObjectifier, _trackTransmitter);
            _output                 = Substitute.For <IOutput>();
            _tracksManager          = Substitute.For <ITracksManager>();
            _airspaceChecker        = Substitute.For <IAirspaceChecker>();
            _uut                    = new TagsManager(_airspaceChecker);
            _courseCalculator       = Substitute.For <ICourseCalculator>();
            _velocityCalculator     = Substitute.For <IVelocityCalculator>();
            _seperationEventChecker = Substitute.For <ISeperationEventChecker>();

            _trackWarehouse = new TrackWarehouse(_uut, _courseCalculator,
                                                 _velocityCalculator, _tracksManager, _seperationEventChecker);
            _atmController = new AtmController(_trackTransmitter, _output, _trackWarehouse);


            _list = new List <string> {
                "ATR423;39045;12932;14000;20151006213456000"
            };

            _trackTransmitter.TrackReady += (o, args) => { _recievedTracks = args.TrackList; };


            // Act
            _transponderReceiver.TransponderDataReady +=
                Raise.EventWith(new RawTransponderDataEventArgs(_list));
        }
Esempio n. 2
0
        public void SetUp()
        {
            _airspaceChecker = Substitute.For <IAirspaceChecker>();
            _uut             = new TagsManager(_airspaceChecker);

            _tracks = new List <Track>
            {
                new Track()
                {
                    Tag = "1"
                },
                new Track()
                {
                    Tag = "2"
                },
                new Track()
                {
                    Tag = "3"
                }
            };

            _tags = new List <string>();

            _airspaceChecker.Check(_tracks[0]).Returns(true);
            _airspaceChecker.Check(_tracks[1]).Returns(true);
            _airspaceChecker.Check(_tracks[2]).Returns(true);
        }
Esempio n. 3
0
 public TagsManager(IAirspaceChecker airspaceChecker)
 {
     _airspaceChecker = airspaceChecker;
 }