Esempio n. 1
0
        public void T00_QualifierExact()
        {
            QualifierExact qe = new QualifierExact("M");

            // test range start/end/key generation

            Assert.AreEqual("=M", qe.genLowestKeyTest());
            Assert.AreEqual("=M", qe.genHighestKeyTest());
            Assert.AreEqual("=M", qe.ToString());

            // test basic key match
            Assert.AreEqual(false, qe.MatchTo(new QualifierExact("A").ToString()));
            Assert.AreEqual(false, qe.MatchTo(new QualifierExact("ZZ").ToString()));
            Assert.AreEqual(true, qe.MatchTo(new QualifierExact("M").ToString()));

            // test exceptions
            // Assert.Fail("need to test exceptions");
        }
Esempio n. 2
0
 public PipeStageMux(
     string context_key, 
     Dictionary<QualifierExact, PipeStage> mux_map, 
     QualifierExact default_muxvalue
     )
 {
     this.mux_map = new Dictionary<QualifierExact, PipeStage>(mux_map);
     this.context_key = context_key;
     this.default_muxvalue = default_muxvalue;
 }