[pygccxml-commit] SF.net SVN: pygccxml:[1405] pygccxml_dev/unittests
Brought to you by:
mbaas,
roman_yakovenko
|
From: <rom...@us...> - 2008-08-25 18:12:06
|
Revision: 1405
http://pygccxml.svn.sourceforge.net/pygccxml/?rev=1405&view=rev
Author: roman_yakovenko
Date: 2008-08-25 18:12:09 +0000 (Mon, 25 Aug 2008)
Log Message:
-----------
add new tester to check infinite loop
Modified Paths:
--------------
pygccxml_dev/unittests/data/indexing_suites2.hpp
pygccxml_dev/unittests/find_container_traits_tester.py
Modified: pygccxml_dev/unittests/data/indexing_suites2.hpp
===================================================================
--- pygccxml_dev/unittests/data/indexing_suites2.hpp 2008-08-21 18:02:50 UTC (rev 1404)
+++ pygccxml_dev/unittests/data/indexing_suites2.hpp 2008-08-25 18:12:09 UTC (rev 1405)
@@ -85,4 +85,8 @@
typedef std::vector<indexing_suites2::item_t*> items_ptr_t;
}}
+namespace infinite_loop{
+ std::map< std::string, int > test_infinite_loop();
+}
+
#endif//__indexing_suites2_to_be_exported_hpp__
Modified: pygccxml_dev/unittests/find_container_traits_tester.py
===================================================================
--- pygccxml_dev/unittests/find_container_traits_tester.py 2008-08-21 18:02:50 UTC (rev 1404)
+++ pygccxml_dev/unittests/find_container_traits_tester.py 2008-08-25 18:12:09 UTC (rev 1405)
@@ -65,7 +65,14 @@
x = 'map<std::string, bool (*)(std::string&, Ogre::MaterialScriptContext&), std::less<std::string>, std::allocator<std::pair<std::string const, bool (*)(std::string&, Ogre::MaterialScriptContext&)> > >'
ct = declarations.find_container_traits( x )
y = ct.remove_defaults( x )
-
+
+ def test_infinite_loop(self):
+ rt = self.global_ns.free_fun( 'test_infinite_loop' ).return_type
+ map_traits = declarations.find_container_traits( rt )
+ self.failUnless( map_traits is declarations.map_traits )
+ elem = map_traits.element_type( rt )
+ self.failUnless( elem.decl_string == 'int' )
+
def create_suite():
suite = unittest.TestSuite()
suite.addTest( unittest.makeSuite(tester_t))
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|