示例#1
0
        public void TestAtomType_String_String()
        {
            IAtomType at = new AtomType("C4", "C");

            Assert.AreEqual("C", at.Symbol);
            Assert.AreEqual("C4", at.AtomTypeName);
        }
示例#2
0
        public void TestAtomType_IElement()
        {
            var       element = ChemicalElement.C;
            IAtomType at      = new AtomType(element);

            Assert.AreEqual("C", at.Symbol);
        }
示例#3
0
        public void TestCompare_DiffBondOrderSum()
        {
            AtomType at1 = new AtomType("C");
            AtomType at2 = new AtomType("C");

            at1.BondOrderSum = 1.5;
            at2.BondOrderSum = 2.0;
            Assert.IsFalse(at1.Compare(at2));
        }
示例#4
0
        public void TestCompare_BondOrderSum()
        {
            AtomType at1 = new AtomType("C");
            AtomType at2 = new AtomType("C");

            at1.BondOrderSum = 1.5;
            at2.BondOrderSum = 1.5;
            Assert.IsTrue(at1.Compare(at2));
        }
示例#5
0
        public void TestCompare_DiffAtomTypeName()
        {
            AtomType at1 = new AtomType("C");
            AtomType at2 = new AtomType("C");

            at1.AtomTypeName = "C4";
            at2.AtomTypeName = "C3";
            Assert.IsFalse(at1.Compare(at2));
        }
示例#6
0
        public void TestCompare_AtomTypeName()
        {
            AtomType at1 = new AtomType("C");
            AtomType at2 = new AtomType("C");

            at1.AtomTypeName = "C4";
            at2.AtomTypeName = "C4";
            Assert.IsTrue(at1.Compare(at2));
        }