Exemple #1
0
        public void Factor()
        {
            double factor = 3.1415927;
            var    unit   = new GimpUnit("foo", factor, 3, "%", "abbr", "foo", "foos");

            Assert.AreEqual(factor, unit.Factor);
        }
Exemple #2
0
 public void Digits()
 {
     int digits = 3;
       var unit = new GimpUnit("foo", 3.1415927, digits, "%", "abbr", "foo",
           "foos");
       Assert.AreEqual(digits, unit.Digits);
 }
Exemple #3
0
 public void Abbreviation()
 {
     string abbreviation = "abbr";
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", abbreviation, "foo",
           "foos");
       Assert.AreEqual(abbreviation, unit.Abbreviation);
 }
Exemple #4
0
        public void Plural()
        {
            string plural = "foos";
            var    unit   = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", plural);

            Assert.AreEqual(plural, unit.Plural);
        }
Exemple #5
0
        public void Singular()
        {
            string singular = "foo";
            var    unit     = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", singular,
                                           "foos");

            Assert.AreEqual(singular, unit.Singular);
        }
Exemple #6
0
        public void Symbol()
        {
            string symbol = "%";
            var    unit   = new GimpUnit("foo", 3.1415927, 3, symbol, "abbr", "foo",
                                         "foos");

            Assert.AreEqual(symbol, unit.Symbol);
        }
Exemple #7
0
        public void Identifier()
        {
            string identifier = "foo";
            var    unit       = new GimpUnit(identifier, 3.1415927, 3, "%", "abbr", "foo",
                                             "foos");

            Assert.AreEqual(identifier, unit.Identifier);
        }
Exemple #8
0
        public void Digits()
        {
            int digits = 3;
            var unit   = new GimpUnit("foo", 3.1415927, digits, "%", "abbr", "foo",
                                      "foos");

            Assert.AreEqual(digits, unit.Digits);
        }
Exemple #9
0
        public void NewGimpUnit()
        {
            int numberOfUnits = GimpUnit.NumberOfUnits;
            var unit          = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", "foos");

            Assert.AreEqual(numberOfUnits + 1, GimpUnit.NumberOfUnits);
            Assert.AreEqual((int)Unit.End, GimpUnit.NumberOfBuiltInUnits);
        }
Exemple #10
0
        public void Abbreviation()
        {
            string abbreviation = "abbr";
            var    unit         = new GimpUnit("foo", 3.1415927, 3, "%", abbreviation, "foo",
                                               "foos");

            Assert.AreEqual(abbreviation, unit.Abbreviation);
        }
Exemple #11
0
 public void DeletionFlag()
 {
     var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", "foos");
       Assert.IsTrue(unit.DeletionFlag);
       unit.DeletionFlag = false;
       Assert.IsFalse(unit.DeletionFlag);
       unit.DeletionFlag = true;
       Assert.IsTrue(unit.DeletionFlag);
 }
Exemple #12
0
        public void DeletionFlag()
        {
            var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", "foos");

            Assert.IsTrue(unit.DeletionFlag);
            unit.DeletionFlag = false;
            Assert.IsFalse(unit.DeletionFlag);
            unit.DeletionFlag = true;
            Assert.IsTrue(unit.DeletionFlag);
        }
Exemple #13
0
 public void Factor()
 {
     double factor = 3.1415927;
       var unit = new GimpUnit("foo", factor, 3, "%", "abbr", "foo", "foos");
       Assert.AreEqual(factor, unit.Factor);
 }
Exemple #14
0
 public void Symbol()
 {
     string symbol = "%";
       var unit = new GimpUnit("foo", 3.1415927, 3, symbol, "abbr", "foo",
           "foos");
       Assert.AreEqual(symbol, unit.Symbol);
 }
Exemple #15
0
 public void Singular()
 {
     string singular = "foo";
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", singular,
           "foos");
       Assert.AreEqual(singular, unit.Singular);
 }
Exemple #16
0
 public void Identifier()
 {
     string identifier = "foo";
       var unit = new GimpUnit(identifier, 3.1415927, 3, "%", "abbr", "foo",
           "foos");
       Assert.AreEqual(identifier, unit.Identifier);
 }
Exemple #17
0
 public void NewGimpUnit()
 {
     int numberOfUnits = GimpUnit.NumberOfUnits;
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", "foos");
       Assert.AreEqual(numberOfUnits + 1, GimpUnit.NumberOfUnits);
       Assert.AreEqual((int) Unit.End, GimpUnit.NumberOfBuiltInUnits);
 }
Exemple #18
0
 public void Plural()
 {
     string plural = "foos";
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", plural);
       Assert.AreEqual(plural, unit.Plural);
 }