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

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

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

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

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

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

            Assert.AreEqual(digits, unit.Digits);
        }
Beispiel #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);
        }
Beispiel #10
0
        public void Abbreviation()
        {
            string abbreviation = "abbr";
            var    unit         = new GimpUnit("foo", 3.1415927, 3, "%", abbreviation, "foo",
                                               "foos");

            Assert.AreEqual(abbreviation, unit.Abbreviation);
        }
Beispiel #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);
 }
Beispiel #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);
        }
Beispiel #13
0
 public void Factor()
 {
     double factor = 3.1415927;
       var unit = new GimpUnit("foo", factor, 3, "%", "abbr", "foo", "foos");
       Assert.AreEqual(factor, unit.Factor);
 }
Beispiel #14
0
 public void Symbol()
 {
     string symbol = "%";
       var unit = new GimpUnit("foo", 3.1415927, 3, symbol, "abbr", "foo",
           "foos");
       Assert.AreEqual(symbol, unit.Symbol);
 }
Beispiel #15
0
 public void Singular()
 {
     string singular = "foo";
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", singular,
           "foos");
       Assert.AreEqual(singular, unit.Singular);
 }
Beispiel #16
0
 public void Identifier()
 {
     string identifier = "foo";
       var unit = new GimpUnit(identifier, 3.1415927, 3, "%", "abbr", "foo",
           "foos");
       Assert.AreEqual(identifier, unit.Identifier);
 }
Beispiel #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);
 }
Beispiel #18
0
 public void Plural()
 {
     string plural = "foos";
       var unit = new GimpUnit("foo", 3.1415927, 3, "%", "abbr", "foo", plural);
       Assert.AreEqual(plural, unit.Plural);
 }