summaryrefslogtreecommitdiff
path: root/tests/Makefile.am
Commit message (Collapse)AuthorAgeFilesLines
* Revert "Try to disable -Wunused-function for the glibmm_interface_move test."Murray Cumming2018-04-221-4/+1
| | | | | | This reverts commit 732df7d9cb709f6fd96099654fb83a00d99f26cf. This doesn't seem to be a problem any more.
* tests: Activate the glibmm_object testKjell Ahlstedt2017-07-031-2/+6
| | | | Probably overlooked in commit 696685eeaa639ae5e41a9eaa761250368af492db
* tests/Makefile.am: Remove the last remnants of glibmm_weakrefKjell Ahlstedt2017-07-031-2/+0
| | | | to avoid some warnings when Makefile is generated from Makefile.am.
* tests/Makefile.am: Fix a typo to fix the build.Murray Cumming2017-04-261-3/+4
|
* tests: Split object_move and objectbase_move tests.Murray Cumming2017-04-091-0/+5
| | | | This allows further reuse of the DerivedObject and DerivedObjectBase test classes.
* tests: glibmm_value: Move code to main.ccMurray Cumming2017-04-071-1/+1
| | | | Which was previously almost empty.
* Remove Glib::WeakRefMurray Cumming2017-04-071-1/+0
| | | | | | | | | | | Now that RefPtr is really a std::shared_ptr<>, we should use std::weak_ref<> instead. Note that a std::weak_ptr<> tells you nothing about whether the underlying GObject is still alive, which Glib::RefPtr did. It just tells you whether our std::shared_ptr<> still holds a reference to it. That's why I removed one of the checks in tests/giomm_listmodel/main.cc.
* Replace remaining uses of Glib::ArrayHandle<> with std::vector.Murray Cumming2017-03-171-5/+0
| | | | | | Using Glib::ArrayHandler<>::vector_to_array() and Glib::ArrayHandler<>::array_to_vector() instead, and only in the implementatoin instead of in the API.
* Added ustring::make_valid() which fixes non-UTF8 strings.Krzysztof Piecuch2017-03-151-1/+3
| | | | | | | | | | | make_valid replaces all non-UTF8 characters with replacement character (U+FFFD). Allows manipulating with ustring after you find out by ustring::validate() that it's not an UTF-8 string and you need to rescue it somehow. This wraps g_utf8_make_valid(). Bug #780075
* Add tests/giomm_stream_vfuncsKjell Ahlstedt2016-11-211-0/+4
| | | | | | | * tests/Makefile.am: Add giomm_stream_vfuncs. * tests/giomm_stream_vfuncs/main.cc: New file. An updated version of a patch by Krzysztof Kosiński <tweenk.pl@gmail.com> Bug #572471
* Remove deprecated API.Murray Cumming2016-11-141-2/+0
|
* Try to disable -Wunused-function for the glibmm_interface_move test.Murray Cumming2016-11-111-1/+4
| | | | | | | | | | | | | | | | | | | To deal with this clang warning when building with --enable-warnings=fatal. TODO: However, this doesn't actually seem to disable the error. glibmm_interface_move/main.cc:9:1: error: unused function 'glib_autoptr_cleanup_TestIface' [-Werror,-Wunused-function] G_DECLARE_INTERFACE(TestIface, test_Iface, TEST, IFACE, GObject) ^ /opt/gnome/include/glib-2.0/gobject/gtype.h:1565:3: note: expanded from macro 'G_DECLARE_INTERFACE' _GLIB_DEFINE_AUTOPTR_CHAINUP (ModuleObjName, PrerequisiteName) \ ^ /opt/gnome/include/glib-2.0/glib/gmacros.h:421:22: note: expanded from macro '_GLIB_DEFINE_AUTOPTR_CHAINUP' static inline void _GLIB_AUTOPTR_FUNC_NAME(ModuleObjName) (ModuleObjName **_ptr) { \ ^ /opt/gnome/include/glib-2.0/glib/gmacros.h:415:43: note: expanded from macro '_GLIB_AUTOPTR_FUNC_NAME' ^ <scratch space>:224:1: note: expanded from here glib_autoptr_cleanup_TestIface
* Add tests/giomm_listmodelKjell Ahlstedt2016-04-271-0/+4
| | | | | Similar to glib/gio/tests/glistmodel.c Bug #755307
* Add Glib::WeakRef<>Kjell Ahlstedt2015-09-151-0/+3
| | | | | | | | | | * glib/glibmm/filelist.am: Add weakref.h. * glib/glibmm/weakref.h: New file. * glib/glibmm.h: Add weakref.h. (Not yet. I'll do it before I push weakref.h.) * tests/Makefile.am: Add test case glibmm_weakref. * tests/glibmm_weakref/main.cc: New test case. Bug #583399. Thanks to worknesday, who attached a first version of WeakRef to the bug report. Bug #583399
* tests: Add glibmm_interface_move.Murray Cumming2015-08-221-0/+2
| | | | | | | | | | | | | | | | | This code got unpleasantly big because I wanted to test a C++ class that wraps a GObject while also implementing a C++ Interface that wraps a GInterface that the GObject implements. But it seems to work. However, the code to test a raw TestInterface is commented out because the move constructor does not pass the test. I am not sure if this should even be expected to work: Interface interface = std::move(object); or: Base base = std::move(derived); Surely that would lose the data (and virtual method table) from the Derived class anyway?
* tests: Split glibmm_object_move into 2 files.Murray Cumming2015-08-221-0/+2
| | | | To test ObjectBase separately.
* Add simple test for Object move.Murray Cumming2015-08-221-0/+2
|
* Add tests/glibmm_refptr.Murray Cumming2015-07-271-0/+2
| | | | | To test refcounting, though I'm not sure that the test for the move constructor is quite right.
* Add Gio::MemoryInputStream testKjell Ahlstedt2014-02-121-0/+4
| | | | | | * tests/giomm_memoryinputstream/main.cc: New file. * tests/Makefile.am: Add the MemoryInputStream test. Bug #609946
* ByteArray: Add some tests for methods returning self.Krzesimir Nowak2013-09-231-3/+5
| | | | | | * tests/Makefile.am: * tests/glibmm_bytearray/main.cc: New file with tests. These are failing now.
* tests: Add the glibmm_mainloop test.Kjell Ahlstedt2013-06-021-0/+2
| | | | | | * tests/glibmm_mainloop/main.cc: New file. Tests MainContext and MainLoop, including MainContext::invoke(). * tests/Makefile.am: Add glibmm_mainloop/test. Bug #668184.
* glibmm: Wrapped Base64 functionality from glibMichael Kruglos2013-05-071-0/+2
| | | | | | | | encoding and decoding are wrapped. step by step and in-place decoding are not wrapped. (they're too low level for C++, and they're available from the C library.) Bug #611589.
* Tests: Add a basic test for the Tls* API.José Alburquerque2013-04-071-0/+4
| | | | | * tests/giomm_tls_client/main.cc: The test basically works though it would be good to test more thoroughly the TlsDatabase API.
* Add a test of implementing an interface.Murray Cumming2013-04-061-0/+5
| | | | | | | * tests/Makefile.am: * tests/glibmm_interface_implementation/main.cc: Add a very simple test that implements an interface, with a vfunc implementation and make sure that the vfunc is called when the caller method is called.
* Avoid use of deprecated API in tests and examples.Murray Cumming2011-10-261-1/+2
| | | | | | | | | | | * tests/Makefile.am: * examples/Makefile.am: Disable deprecated API. * examples/network/socket-client.cc: * examples/network/socket-server.cc: * examples/thread/dispatcher.cc: * examples/thread/dispatcher2.cc: * examples/thread/thread.cc: Remove calls to Glib::thread_init(), instead calling Glib::init() where that side-effect was also intended.
* Fix the make check build by always linking to gthread-2.0.Murray Cumming2011-10-251-1/+1
| | | | | | | | | | | | | * configure.ac: Always use gthread-2.0 because there is now no advantage to not doing that, because threading is now always enabled in glib. Remove the separate GTHREAD* variables. * glib/glibmm/Makefile.am: * gio/giomm/Makefile.am: * tests/Makefile.am: * tools/Makefile.am: * examples/Makefile.am: Remove use of the GTHREAD* variables.. * examples/network/resolver.cc: Remove the non-threading option and code that uses it.
* Add reftpr_sigc_bind test case.Murray Cumming2011-07-191-1/+3
| | | | | | * tests/glibmm_refptr_sigc_bind/main.cc: * tests/Makefile.am: Add a new test case from Kjell Ahlstedt, to test a fix in libsigc++. See bug #564005#c14.
* Vectorutils, ArrayHandle: Check for NULL pointers.Krzesimir Nowak2011-03-211-16/+22
| | | | | | | | | | | | | | | * glib/glibmm/vectorutils.[h|cc]: Don't crash in compute_array_size2, when NULL is passed - in that case just return 0. Also, array_to_vector method return empty vector in such case. * glib/glibmm/arrayhandle.[h|cc]: Set array_size to zero if passed array is NULL. * tests/glibmm_null_vectorutils/main.cc: New test for NULL arrays and lists for vectorutils. * tests/glibmm_null_containerhandle/main.cc: New test for NULL arrays and lists for containerhandles. * tests/Makefile.am: Added new tests to build. Spotted by Kalev Lember. Bug #645245.
* Actually run all tests, and check some failures.Murray Cumming2011-02-241-1/+1
| | | | | | | | | | | | | | | | | | | * tests/Makefile.am: Add all tests to TESTS so they are really run during make check, instead of just built. * tests/giomm_asyncresult_sourceobject/main.cc: * tests/giomm_ioerror/main.cc: * tests/giomm_simple/main.cc: * tests/glibmm_bool_arrayhandle/main.cc: * tests/glibmm_bool_vector/main.cc: * tests/glibmm_buildfilename/main.cc: * tests/glibmm_date/main.cc: * tests/glibmm_ustring_compose/main.cc: * tests/glibmm_valuearray/main.cc: * tests/glibmm_variant/main.cc: * tests/glibmm_vector/main.cc: Remove all use of std::cout by default, allowing it to be renabled by changing a line. Return (or) exit with EXIT_FAILURE after any use of std::cerr, so that make check can report it.
* Rename Gio::DBus::DBusError to Gio::DBus::Error.Murray Cumming2011-02-241-0/+6
| | | | | | | | | | | * gio/src/dbuserror.hg: Rename the class to Error. * examples/dbus/busserver.cc: Adapated. * tests/giomm_ioerror_and_iodbuserror/main.cc: Added a test to check that both Gio::Error and Gio::DBus::Error are working. * tests/Makefile.am: Set TESTS, so that the test is actually run. We should add others to this too. This current fails, so I need to fix the problem in a subsequent commit.
* Added missing files.Krzesimir Nowak2011-02-211-2/+2
|
* Extended build_filename() utility functionFabrício Godoy2011-02-211-0/+2
| | | | | Extended build_filename() to accept up to nine parameters. Added a new testcase in tests/glibmm_buildfilename.
* Added bool specialization for Glib::ArrayHandle.Krzesimir Nowak2011-02-211-25/+27
| | | | | | | | | | | * glib/glibmm/arrayhandle.h: Added specialization for bool ArrayHandle. This is needed because std::vector<bool> is a specialization for which iterators does not return a reference to actual value it holds. * glib/glibmm/arrayhandle.cc: New file implementing destructor of bool ArrayHandle - the only method that is not inlined. * tests/glibmm_bool_arrayhandle/main.cc: New file implementing test checking if bool ArrayHandle actually works. * tests/Makefile.am: Added new test to build.
* Added vectorutils.h.Krzesimir Nowak2011-01-271-2/+7
| | | | | | | | | | | * glib/glibmm/vectorutils.[h|cc]: New files implementing an array, list, slist <-> std::vector convertions. It implements also a specialization for bool types. * glib/glibmm.h: Include vectorutils.h. * glib/glibmm/filelist.am: Added vectorutils to build. * tests/glibmm_vector/main.cc: New test for general vectorutils check. * tests/glibmm_bool_vector/main.cc: New test checking bool specializations. * tests/Makefile.am: Added above tests to build system.
* Add a valuearray test to build.Krzesimir Nowak2010-12-241-2/+1
| | | | | * tests/Makefile.am: Added a valuearray test to build instead of value test thrice.
* Variant: Add a VariantStringBase and a VariantContainerBase class.José Alburquerque2010-12-201-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * glib/src/variant.{ccg,hg} (VariantStringBase): Implement a new class from which the Glib::Variant<> string class (like Glib::Variant<Glib::ustring>) now derive. The new class has methods for determining/creating object paths and signatures. The new instances are created by setting output parameters. (VaraintContainerBase): Implement this new class from which variant containers should derive. (VariantContainerBase::get_n_children, get, get_maybe): Moved from Variant<VariantBase> (castitem constructors): Corrected all GVariant* castitem constructors to accept a 'take_a_reference' bool parameter. (Variant< std::vector<T> >::create, get, get_iter): Re-wrote these methods to use the Glib::VariantType class to get variant types instead of using strings. Also Re-wrote to work specifically with fixed arrays (see g_variant_get_fixed_array). This means that this class will not work with vectors of strings because g_variant_get_strv() and g_variant_get_bytestring_array() need to be used in those cases. (std::vector<T> get): Re-wrote to use an output parameter. * glib/src/variant_basictypes.h.m4: Corrected the castitem constructors as above. * tests/Makefile.am: * tests/glibmm_variant/main.cc: Added a small test for the Variant< std::vector<T> > methods. * gio/src/dbuserror.hg: * gio/src/error.hg: Wrap the GDBusError enum as a GError, moving its declaration to error.hg.
* Add regression test for Bug #613250.Murray Cumming2010-03-261-1/+3
| | | | | | * tests/Makefile.am * tests/glibmm_ustring_format/main.cc: Added a regression test for the previously-commited fix, based on code in bug #613250 from Debarshi Ray.
* Reorder assignment to LDADD and giomm_ldadd in tests/Makefile.amDavid King2010-03-101-3/+3
| | | | | | * tests/Makefile.am: Reorder values assigned to LDADD and giomm_ldadd to place built libraries before system libraries. Fixes GNOME bug #610854.
* AsyncResult: Add get_source_object_base(), deprecating get_source_object().Murray Cumming2010-03-081-1/+6
| | | | | | | | | | * gio/asyncresult.[hg|ccg]: Deprecate get_source_object(), replacing it with get_source_object_base(), because in giomm, the C++ wrapper object might be a Glib::Interface, but not a Glib::Object (though the underlying C instance must be a GObject). This happens if giomm does not know about the GType of the underlying C Object, which is a legitimate situation. * tests/giomm_asyncresult_sourceobject/main.cc: Added this test case from Michael Hasselmann, from bug #608269.
* Implement GTree wrapperSzilárd Pfeiffer2010-01-051-0/+2
| | | | Also add some tests for the new class
* Convert tests/ sub-tree to non-recursive buildDaniel Elstner2009-08-091-4/+50
| | | | | | | | | | * tests/Makefile.am: Rewrite to a non-recursive build of all test programs with a single control file. Hook the the build of the test programs to the make check target. * tests/Makefile.am_fragment: Delete obsolete file. * tests/*/Makefile.am: Delete obsolete files. * configure.ac (AC_CONFIG_FILES): Remove tests/*/Makefile output files from the list.
* Add Glib::ValueArray with usage test.José Alburquerque2009-06-221-1/+2
|
* Added a test case. Added a ustring::Stringify<> template specialization soMurray Cumming2008-08-061-1/+1
| | | | | | | | | | | | | | | 2008-08-06 Murray Cumming <murrayc@murrayc.com> * configure.in: * tests/Makefile.am: * tests/glibmm_ustring_compose/main.cc: Added a test case. * glib/glibmm/ustring.h: Added a ustring::Stringify<> template specialization so that ustring::compose() works with const char* arguments, though it still needs to be fixed to work for string literals. Bug #506410 (Szilárd Pfeiffer). svn path=/trunk/; revision=711
* Renamed to nodetree.hgMurray Cumming2008-07-291-1/+1
| | | | | | | | | | | | | | | 2008-07-29 Murray Cumming <murrayc@murrayc.com> * configure.in: * glib/glibmm.h: * glib/src/Makefile_list_of_hg.am_fragment: * glib/src/nodetree.hg: * glib/src/tree.hg: Renamed to nodetree.hg * tests/Makefile.am: * tests/glibmm_tree/Makefile.am: * tests/glibmm_tree/main.cc: Renamed to glibmm_nodetree/ svn path=/trunk/; revision=700
* Added the drive_eject_button signal.Murray Cumming2008-07-251-1/+1
| | | | | | | | | | | | | | | | | | | | | 2008-07-25 Murray Cumming <murrayc@murrayc.com> * gio/src/volumemonitor.hg: Added the drive_eject_button signal. 2008-07-25 Murray Cumming <murrayc@murrayc.com> * gio/src/gio_enums.defs: Hacked in a replacement enum for Gio::Error::HOST_NOT_FOUND as Gio::Error::HOST_WAS_NOT_FOUND, to avoid a clash with a netdb.h define. Bug #529496. * configure.in: * tests/Makefile.am: * tests/giomm_ioerror/Makefile.am: * tests/giomm_ioerror/main.cc: Added a test to make sure that our hacked-in enum value stays hacked in. svn path=/trunk/; revision=695
* Added Glib::Tree, a wrapper for GNode, providing an N-ary tree container,Levi Bard2008-06-131-1/+1
| | | | | | | | | | | | | | | | 2008-06-13 Levi Bard <taktaktaktaktaktaktaktaktaktak@gmail.com> * glib/glibmm.h: * glib/glibmm/Makefile.am: * glib/src/Makefile_list_of_hg.am_fragment: * glib/src/tree.ccg: * glib/src/tree.hg: Added Glib::Tree, a wrapper for GNode, providing an N-ary tree container, more or less like a standard C++ container. * configure.in: * tests/Makefile.am: Added some test code for this new API. Bug #520778 svn path=/trunk/; revision=667
* Added copy constructor and assignment operator; Made GDate constructorJosé Alburquerque2008-06-101-1/+1
| | | | | | | | | | | | | | | 2008-06-09 José Alburquerque <jaalburqu@svn.gnome.org> * glib/src/date.ccg: * glib/src/date.hg: Added copy constructor and assignment operator; Made GDate constructor visible. * configure.in: * tests/Makefile.am: * tests/glibmm_date/Makefile.am: * tests/glibmm_date/main.cc: Added simple test to test Glib::Date. svn path=/trunk/; revision=661
* Copy (and very slightly adjust) the build_shared/ files from gtkmm, whichMurray Cumming2008-01-101-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-01-10 Murray Cumming <murrayc@murrayc.com> * Makefile.am: * build_shared/Makefile_build.am_fragment: * build_shared/Makefile_build_extra.am_fragment: * build_shared/Makefile_build_gensrc.am_fragment: * build_shared/Makefile_gensrc.am_fragment: * build_shared/Makefile_gensrc_platform.am_fragment: Copy (and very slightly adjust) the build_shared/ files from gtkmm, which has had multiple sub-libraries for a long time. * gio/giomm/Makefile.am: * gio/src/Makefile.am: * gio/src/Makefile_list_of_hg.am_fragment: * glib/glibmm/Makefile.am: * glib/glibmm/private/Makefile.am: * glib/src/Makefile.am: * glib/src/Makefile_list_of_hg.am_fragment: Adapt to the structure (variable names, mostly) needed by the newer build_shared/ files, so that the giomm library is actually built. * tools/m4/convert_glib.m4: * gio/giomm/init.cc: * gio/giomm/init.h: * gio/src/asyncresult.ccg: * gio/src/drive.ccg: * gio/src/drive.hg: * gio/src/file.ccg: * gio/src/file.hg: * gio/src/fileattribute.ccg: * gio/src/fileinputstream.hg: * gio/src/fileoutputstream.hg: * gio/src/volume.ccg: * gio/src/volume.hg: Various build fixes, including adding a flags parameter to unmount and eject methods. svn path=/trunk/; revision=497
* Correct an include.Murray Cumming2008-01-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2008-01-10 Murray Cumming <murrayc@murrayc.com> * gio/giomm.h: Correct an include. * gio/src/asyncresult.hg: * gio/src/cancellable.hg: * gio/src/drive.hg: * gio/src/file.hg: * gio/src/fileattribute.hg: * gio/src/fileenumerator.hg: * gio/src/fileicon.hg: * gio/src/fileinfo.hg: * gio/src/fileinputstream.hg: * gio/src/fileoutputstream.hg: * gio/src/outputstream.hg: * gio/src/simpleasyncresult.hg: * gio/src/volume.ccg: * gio/src/volume.hg: Correct several includes to use giomm/ instead of glibmm/. * configure.in: * examples/Makefile.am_fragment: * tests/Makefile.am_fragment: Include/Link giomm too. * tests/Makefile.am: * tests/giomm_simple/Makefile.am: * tests/giomm_simple/giomm_simple.cc: Added a little test, which shows that the library is not being built properly - we get undefined symbols. svn path=/trunk/; revision=496
* It now builds, though I haven' tried installing it. The library names andMurray Cumming2003-01-081-4/+1
| | | | | | | | 2003-01-08 Murray Cumming <murrayc@usa.net> * It now builds, though I haven' tried installing it. The library names and header directories should now all have 2.4 instead of 2.0 in their name.