Commit Graph

93 Commits

Author SHA1 Message Date
Christian Mazakas 0ac4aeca50 Add swap_exception_tests for FOA, only testing weak exception guarantee 2022-10-19 11:05:09 -07:00
Christian Mazakas 4de1be8911 Add the rest of the exception tests sans swap 2022-10-18 15:54:02 -07:00
Christian Mazakas aa41ab4195 Add constructor_exception tests for FOA 2022-10-17 13:19:29 -07:00
Christian Mazakas 48765e82e0 Update tests to account for a default-constructed container having no buckets 2022-08-30 15:20:31 -07:00
Christian Mazakas d20be2aaf8 Refactor tests to disable -Wself-assign-overloaded themselves instead of in the Jamfile as not all clang versions support the warning 2022-02-11 11:33:11 -08:00
Daniel James cfd4bacc2c Stop using BOOST_DEDUCED_TYPENAME
We no longer support any of the compilers that require it. I'd be very
surprised if anything was working on them.
2018-01-27 09:39:59 +00:00
Daniel James f7665a2743 Another attempt to fix insert_exception_tests on Visual C++ 7.1
Try extracting the nested template structs.
2018-01-20 08:57:56 +00:00
Daniel James e64c5b34df Try to fix insert_exception_tests on Visual C++ 7.1
It doesn't seem to like the nested template structs. If this doesn't work, I'll
try moving them into the top level.
2018-01-17 10:24:07 +00:00
Daniel James ce0f16f328 Missing copyright messages 2018-01-10 15:15:09 +00:00
Daniel James 07758b7af8 Catch exceptions by reference 2017-12-22 17:02:13 +00:00
Daniel James 613f154d47 Improved test formatting 2017-10-09 12:34:47 +01:00
Daniel James 0676b4f4ca Change clang format indentation + .editorconfig file 2017-06-11 20:55:59 +01:00
Daniel James dc611fc828 Run fewer test in merge_exception_tests
It's timing out on some platforms because it's too slow. This reduces
the tag combinations for 9 to 3, which should reduce the execution time
by a third. Also slightly reduces the count combinations, but that won't
make much of a difference really - the slowest tests are still there
(when the right hand side is large).
2017-05-14 02:59:22 +01:00
Daniel James ca80237191 Create fewer classes in merge_exception_tests
Will need better error reporting capabilities. Makes RUN_TESTS_QUIET
redundant?
2017-05-10 19:02:47 +01:00
Daniel James b95ef6de04 Generate less output in merge_exception_tests 2017-05-10 19:02:47 +01:00
Daniel James 76e7322262 Use streams from lightweight test 2017-05-10 19:02:47 +01:00
Daniel James 1b0b38a519 try_emplace, insert_or_assign exception tests 2017-05-07 18:47:59 +01:00
Daniel James 9119a42b7d Factor insert_exception_tests for better code reuse 2017-05-07 18:47:24 +01:00
Daniel James 8af4b37d14 Rewrite insert exception tests
Not going to do this for all the tests. It's more effort than I
expected.
2017-05-07 17:54:34 +01:00
Daniel James 31c5b5bfa1 Merge exception tests 2017-05-07 17:54:34 +01:00
Daniel James 0489069419 Use 'limited_range' to catch error in exception tests
This would have caught the error fixed in 3fe259a79e.
2017-05-06 04:47:59 +01:00
Daniel James 597eb5a3fd Repeat the assign/insert exception tests a few times 2017-05-06 04:47:59 +01:00
Daniel James 6ef17a0f0e Remember to disable exceptions before checking final value 2017-05-05 00:46:07 +01:00
Daniel James 47a8c3fc67 Fix exception handling in rehash_impl
And improve tests so they will catch the error, and other similar errors.
2017-05-04 19:30:18 +01:00
Daniel James bf5ef9824d Reformat with clang-format 2017-02-19 13:05:17 +00:00
Daniel James b2f2fdc2f3 Prevent clang-format sorting some test includes 2017-02-19 13:05:17 +00:00
Daniel James 57cc6d4bac Fix exception safety when constructing pairs 2017-01-01 18:35:50 +00:00
Daniel James 74abdd6973 Replace boost::next with a simpler version
Less optimized, but hopefully it won't cause any warnings.
2016-10-11 13:36:41 +01:00
Daniel James a316d3fa46 Fix more warnings 2016-10-11 10:07:07 +01:00
Daniel James 71d19820ac Fix signed conversion warnings. 2016-10-05 09:45:53 +01:00
Daniel James e7b20d2877 Fix exception bug in asssignment.
The hash and key equality functions were assigned before allocating new
buckets. If that allocation failed, then the existing elements would be
left in place - so if accessed after the exception they could be in the
wrong buckets or equivalent elements could be incorrectly grouped
together.
2016-10-02 13:04:25 +01:00
Daniel James 98462fbcc3 Avoid conversion warning. 2016-10-01 13:53:05 +01:00
Daniel James 1c606980ec Update tests for standard changes involving bucket count.
It seems my defect report was accepted at some point, and they tweaked
the requirements involving bucket counts. This also makes it possible to
have a bucket count of 0, which I think wasn't allowed in the past. I
don't think I'll change this implementation to do so, but I'd like to be
able to run these tests against standard implementations, so I'm
starting to take that into account.

I believe these changes were made after the C++14 standard, but I've
always been tracking the draft standards, so that doesn't really matter.
2016-09-18 12:22:48 +01:00
Daniel James 9debeadee7 Fix some test warnings.
And turn on warnings as errors in Travis.
2016-08-17 12:08:16 +01:00
Daniel James 59cbe3d483 Also move exception tests into test/Jamfile.v2
Moving the tests successfully restored the test results, so do it for
the exception tests as well.
2016-07-03 08:42:17 +01:00
Daniel James b4a3c6f460 Fix exception safety in assignment for multimap/multiset.
The assignment code seemed like a bit of a premature optimization, I
replaced it with a slightly slower but much simpler implementation.
2016-05-30 15:02:04 +01:00
Daniel James 15cb6d7d1b Tweak warning flags in tests. 2014-07-14 21:49:58 +01:00
Daniel James 10049f8325 Unordered: Missing final newlines.
[SVN r81761]
2012-12-07 17:05:36 +00:00
Marshall Clow 1bd3b029fa Removed usage of deprecated macros
[SVN r81563]
2012-11-26 17:47:12 +00:00
Daniel James 2e26534659 Unordered: Improved exception test thing.
Allows repetition of exception tests + separate running the tests so that
different tests types or configurations can be mixed up.

[SVN r81030]
2012-10-21 00:20:07 +00:00
Daniel James f1e716d897 Unordered: Stronger assign testing.
[SVN r80227]
2012-08-25 21:55:46 +00:00
Daniel James aefea862c2 Unordered: Two exception testing allocators.
For different C++11 properties.

[SVN r80225]
2012-08-25 21:54:50 +00:00
Daniel James 98083078a3 Unordered: Remove malloc_allocator.
It was originally introduced because of some issues with Boost.Test and older
compilers, neither of which I'm using now. Simplifies a few things.

[SVN r79352]
2012-07-08 11:53:39 +00:00
Daniel James 275b03e76b Unordered: Avoid -Wshadow warnings. Refs #6190.
[SVN r78364]
2012-05-07 10:57:35 +00:00
Daniel James c8c71d0ad1 Unordered/hash: Avoid a gcc warning. Refs #6771
[SVN r77832]
2012-04-08 15:29:15 +00:00
Daniel James 03245c80ff Unordered: Turn off warnings as errors and debug libs.
I'm getting a warning from another library. I don't really need to check
debug libs anymore - that was for container_fwd which is now tested in
details.

[SVN r74840]
2011-10-09 07:56:28 +00:00
Daniel James 0e5930b8dc Unordred: Implement propagate_on_container_swap.
[SVN r73680]
2011-08-11 21:18:43 +00:00
Daniel James daad24388c Fix iterator insert bug in unordered_set/unordered_map.
[SVN r66136]
2010-10-21 20:23:37 +00:00
Daniel James 3a13ddb4a3 Don't use _GLIBCXX_DEBUG on darwin.
It isn't supported by Apple's gcc 4.2.

[SVN r63449]
2010-06-30 12:04:41 +00:00
Daniel James ea33b5d134 Fix clang warnings in unordered tests.
[SVN r61505]
2010-04-23 07:26:43 +00:00