示例#1
0
        public override void EnableBoard()
        {
            Dictionary <string, string> param = CreateParam(_boardName, _floorNum, _boardNum, _ovenPort, _ctlPort);
            BaseProtocol    protocol          = MockBaseProtocol();
            BaseOvenControl ovenCtrol         = MockBaseOvenControl();
            IBoard          test = new CFP8TOSA(protocol, ovenCtrol, param, this._logger);

            this._logger.Info("Add seats:");
            for (int i = 1; i <= 16; i++)
            {
                test.AddSeat(i, string.Format("SN_{0:D2}", i));
            }
            this._logger.Info("Enable board:");
            test.EnableBoard();
        }
示例#2
0
        public override void CheckConnections()
        {
            Dictionary <string, string> param = CreateParam(_boardName, _floorNum, _boardNum, _ovenPort, _ctlPort);
            BaseProtocol    protocol          = MockBaseProtocol();
            BaseOvenControl ovenCtrol         = MockBaseOvenControl();
            IBoard          test = new CFP8TOSA(protocol, ovenCtrol, param, this._logger);

            this._logger.Info("Add seats:");
            for (int i = 1; i <= 16; i++)
            {
                test.AddSeat(i, string.Format("SN_{0:D2}", i));
            }
            this._logger.Info("Check connections:");
            Dictionary <int, bool> ret = test.CheckConnections();

            foreach (var info in ret)
            {
                this._logger.Info("Connections status:" + info.Key + " = " + info.Value);
            }
            foreach (var info in ret)
            {
                Assert.AreEqual(true, info.Value);
            }
        }