Ejemplo n.º 1
0
 def test_Prototype_2(self):
     testObj = FunctionPrototype(
         "const bool DoSomething(const NameSpace::NameSpace1::ArgType1& arg1, const NameSpace::NameSpace1::ArgType2& arg2) const"
     )
     prototype = "const bool DoSomething(const NameSpace::NameSpace1::ArgType1&, const NameSpace::NameSpace1::ArgType2&) const"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)
Ejemplo n.º 2
0
 def test_Prototype_9(self):
     testObj = FunctionPrototype(
         "const bool DoSomething(const ArgType1& arg1, const ArgType2& arg2) const"
     )
     prototype = "const bool DoSomething(const ArgType1* arg1, const ArgType2* arg1) const"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, False)
Ejemplo n.º 3
0
 def test_Prototype_36(self):
     testObj = FunctionPrototype(
         "DoSomething(const ArgType1* const arg1, const ArgType2* const arg2)"
     )
     prototype = "const bool DoSomething(const ArgType1 *const a, const ArgType2 *const b) const"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)
Ejemplo n.º 4
0
 def test_Prototype_21(self):
     testObj = FunctionPrototype(
         "void NameSpace::DoSomeThing(NameSpace::ArgType1 a, NameSpace::ArgType2 b)"
     )
     prototype = "void NameSpace::DoSomeThing(NameSpace::ArgType1, NameSpace::ArgType2)"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)
Ejemplo n.º 5
0
 def test_Prototype_20(self):
     testObj = FunctionPrototype(
         "const bool DoSomething(std::__cxx11::vector& arg1, const std::__cxx11::string& arg2) const"
     )
     prototype = "const bool DoSomething(std::vector& a, const std::string& b) const"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)
Ejemplo n.º 6
0
 def test_Prototype_25(self):
     testObj = FunctionPrototype("void DoSomeThing() const")
     prototype = "void DoSomeThing(void) const"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)
Ejemplo n.º 7
0
 def test_Prototype_22(self):
     testObj = FunctionPrototype("void DoSomeThing(ArgType1 a)")
     prototype = "void DoSomeThing(ArgType1)"
     ret = testObj.CheckMatch(prototype)
     self.assertEqual(ret, True)