Exemplo n.º 1
0
        public void EmptyContractVisibilityTest()
        {
            var function = new ContractFunction()
            {
                Name = "Test"
            };

            function.GenerateCode(new Indentation());
        }
Exemplo n.º 2
0
        public void InvalidContractNameTest()
        {
            var function = new ContractFunction()
            {
                Name = "123"
            };

            function.GenerateCode(new Indentation());
        }
Exemplo n.º 3
0
        public void ModificationTypeXorIsPayableTest2()
        {
            var function = new ContractFunction()
            {
                Name             = "Test",
                Visibility       = Visibility.Public,
                ModificationType = ModificationType.View,
                IsPayable        = true
            };

            function.GenerateCode(new Indentation());
        }
Exemplo n.º 4
0
 public void GenerateCodeTest(ContractFunction function, Indentation indentation, string expected)
 {
     System.Diagnostics.Contracts.Contract.Requires(function != null);
     Assert.AreEqual(expected, function.GenerateCode(indentation));
 }
Exemplo n.º 5
0
        public void EmptyContractNameTest()
        {
            var function = new ContractFunction();

            function.GenerateCode(new Indentation());
        }