Example #1
0
        public bool GetTestOutcome()
        {
            bool ret = false;

            TestRecord tr = new TestRecord();

            if (this.TestRecords.Count > 0)
            {
                //tr = this.TestRecords[0];                       // the first element of the list, index starts from 0
                tr = this.TestRecords.FirstOrDefault();
                if (tr.ErrorCode == 0)
                {
                    ret = true;
                }
            }
            return(ret);
        }
Example #2
0
        private void SelectTblAllOps()
        {
            string sqlCmd = string.Format("select TestDate, TestErrorCode from TestTracker where Baseplate = '{0}' order by Operation, TestDate", this.SerialNumber);

            dbAccess.SetQueryCmd(sqlCmd);
            DataTable dt = dbAccess.ReadDbData();

            if (dt.Rows.Count > 0)
            {
                foreach (DataRow dRow in dt.Rows)
                {
                    TestRecord tr = new TestRecord();
                    tr.DateTime  = (DateTime)dRow["TestDate"];
                    tr.ErrorCode = (int)dRow["TestErrorCode"];

                    this.TestRecords.Add(tr);
                }
            }
        }