public void Setup()
 {
     _uut = new TrackEnteredAirspace(_atmLog = Substitute.For<IATMLogEvent>());
     _atmTransponderData1 = Substitute.For<IATMTransponderData>();
     _atmTransponderData2 = Substitute.For<IATMTransponderData>();
     _atmTransponderData1.Tag = "item1";
     _atmTransponderData1.Timestamp = "1221";
     _atmTransponderData2.Tag = "item2";
 }
        public void EventHandler_Logging_TrackEnteredAirspaceEvent()
        {
            File.WriteAllText(@"ATMLogger.txt", "Cleared");
            var trackEnteredAirspace = new TrackEnteredAirspace();
            var atmEventHandler = new ATMEventHandler(new List<ATMWarning> { _separation }, new List<ATMNotification> { trackEnteredAirspace, _trackLeftAirspace });
            atmEventHandler.Handle(new List<IATMTransponderData> { new ATMTransponderData("EventHandler_Log_TrackEnteredAirspaceEventTest", 17650, 29874, 5000, "2015") });

            var fileConsistOurString = (File.ReadLines(@"ATMLogger.txt").Last()).Contains("EventHandler_Log_TrackEnteredAirspaceEventTest");

            Assert.IsTrue(fileConsistOurString);
        }
 public void Setup()
 {
     _trackEnteredAirspace = new TrackEnteredAirspace(Substitute.For<IATMLogEvent>());
     _trackLeftAirspace = new TrackLeftAirspace(Substitute.For<IATMLogEvent>());
 }
 public void Setup()
 {
     _atmLogEvent = Substitute.For<IATMLogEvent>();
     _separation = new Separation(_atmLogEvent);
     _trackEnteredAirspace = new TrackEnteredAirspace(_atmLogEvent);
     _trackLeftAirspace = new TrackLeftAirspace(_atmLogEvent);
     _atmEventHandler = new ATMEventHandler(new List<ATMWarning> { _separation }, new List<ATMNotification> { _trackEnteredAirspace, _trackLeftAirspace });
 }