2
0
mirror of https://github.com/boostorg/nowide.git synced 2026-01-19 04:22:12 +00:00

244 Commits

Author SHA1 Message Date
Alexander Grund
1813b73ac6 Don't search for Boost.system (header-only) in CMake test file 2025-10-28 09:31:23 +01:00
Alexander Grund
0768ece5cc Update required Boost version to 1.66
B2 doesn't build on some newer compilers anymore so we can't properly
test it.
As 1.66 is "old enough" by now just use that.
2025-10-23 14:30:58 +02:00
Rene Rivera
ef9415cea3 Sync from upstream. 2025-04-04 21:41:28 -05:00
Alexander Grund
015be201a5 Fix test for coverage 2024-10-19 14:02:15 +02:00
Alexander Grund
00c8a9af2e Enhance buffering and target stream handling of iostreams
buffering may be independent of tied streams, so make it an extra param
2024-10-19 14:02:15 +02:00
Alexander Grund
64ae4e0c28 Add test for buffering behavior of iostreams
Closes #186
2024-10-19 14:02:15 +02:00
Rene Rivera
0b38173510 Sync from upstream. 2024-05-17 17:35:24 -05:00
Alexander Grund
213c99cd4c CMake: Build tests only on make test (#182)
Add EXCLUDE_FROM_ALL to test binaries as per the Boost convention
2024-05-16 19:33:16 +02:00
Rene Rivera
a4d7bd27a6 Add missing use dep for building the file_test_helpers lib. 2024-05-03 19:18:48 -05:00
jackarain
3c4e04597c Fix warning '_CRT_SECURE_NO_WARNINGS': macro redefinition 2023-12-25 15:14:59 +08:00
Alexander Grund
b7a4fa5f56 Include iomanip before checking feature macros 2023-11-04 10:31:27 +01:00
Alexander Grund
26bc5d540e Avoid warning in test 2023-11-03 14:46:45 +01:00
Alexander Grund
2c40bddb30 Reduce duplicated requirements from Jamfiles 2023-06-22 16:24:52 +02:00
Alexander Grund
af2b3f5af7 Fix duplicated PRIVATE in CML 2023-06-22 16:24:52 +02:00
Alexander Grund
149ee7c84e Fix false positive warning in GCC 13 on MinGW 2023-06-21 16:58:23 +02:00
Alexander Grund
1e92987a04 Add boost::nowide::quoted to read/write paths from/to streams. 2023-03-04 16:48:25 +01:00
Alexander Grund
75f7b51616 Fix potential macro redefinition in test_traits
Check that `_SILENCE_EXPERIMENTAL_FILESYSTEM_DEPRECATION_WARNING` is not
defined already before defining it to avoid a warning (e.g. C4005 on MSVC)

Fixes #165
2022-09-27 17:39:11 +02:00
Alexander Grund
fed43a678b Remove uneccessary cast in test_swap
The cast is actually wrong as the return value of `get` is `int` already.
2022-07-13 12:53:21 +02:00
Alexander Grund
a0327e0b74 Update license headers
Use the more concise format omitting the reference to the license file
and refer to the URL only.
2022-07-13 12:35:54 +02:00
Alexander Grund
5aa0b5ba55 Add tests for const path::value_type*
Add some `static_assert`s checking that the filebuf and fstream classes
can be used with `const *::filesystem::path::value_type*`
Closes #153
2022-06-26 20:20:38 +02:00
Alexander Grund
993deff3ca Coverity: Remove space in supression comments
Seemingly the correct syntax is without that space.
2022-06-14 12:50:04 +02:00
Alexander Grund
668165bad2 Catch any exception in benchmark
Coverity detected a potential `bad_cast` due to facets in iostreams and
`bad_array_new_length` during `vector` construction.
Catch those too with the more general `std::exception` although they are
very likely false positives / can never occur.
2022-06-14 12:37:53 +02:00
Alexander Grund
9ae1a23619 Coverity: Mark negative counts to xsputn/xsgetn as intended 2022-06-14 12:37:53 +02:00
Alexander Grund
401940e7c3 Test: filebuf xsgetn/xsputn & write-only/read-only buf 2022-06-12 14:00:27 +02:00
Alexander Grund
f2eec7760f Simplify pbackfail allowing only limited putback
There are too many corner cases in putback handling.
As use of that is rare anyway do the bare minimum and only allow putback into the current (read) buffer.
2022-06-10 13:02:26 +02:00
Alexander Grund
4c1bfb3020 Add test for pbackfail/sungetc/sputbackc 2022-06-10 13:02:25 +02:00
Alexander Grund
d078cfe3ac Add search paths for relative includes
Required for e.g. recent Cygwin where the current source files path is not added to the search path automatically.
2022-06-01 12:57:22 +02:00
Alexander Grund
5534a49455 Merge pull request #155 from Flamefire/fix-flush
Fix use of fflush and enhance filebuf tests
2022-05-25 14:13:37 +02:00
Alexander Grund
97fa18f156 Add more tests for filebuf 2022-05-25 11:09:42 +02:00
Alexander Grund
506e899b2e Tests: Add TEST_CONTEXT 2022-05-24 14:06:09 +02:00
Alexander Grund
206cb43340 Fix MSYS2 builds 2022-05-24 13:46:23 +02:00
Alexander Grund
4cea2fff0c Fix MSYS2 builds 2022-05-23 17:06:22 +02:00
Alexander Grund
9acb785499 Reenable fstream benchmark code
Was accidentally left commented out
2022-05-23 15:52:44 +02:00
Alexander Grund
0a3db91f98 Fix -Wundef warnings 2022-03-26 17:44:38 +01:00
Alexander Grund
0987b8d7af Consistently use nullptr instead of NULL/0 2022-03-18 11:22:19 +01:00
Alexander Grund
b8cb76291d CI: Skip flaky test-part on affected Appveyor images
Creating console input events fails sporadically on recent Appveyor images when using CMake/CTest.
Add an option to disable that and use it for the recent Appveyor image
2022-03-18 11:22:19 +01:00
Alexander Grund
fe2c27917e SetConsoleMode for StdIn in iostream integration test
Some modes seem to be incompatible with certain CI environments, e.g. newer Appveyor images making test fail sometimes.
Set a known "good" mode to avoid this.
2022-03-18 11:22:19 +01:00
Alexander Grund
d0c9fea797 Add test reopening an ofstream after close()
Based on code reported at #150
2022-03-18 11:22:19 +01:00
Alexander Grund
b88a6d599e Compile and run test_traits only once
Combine the with and without Boost.Filesystem cases into 1 test
2022-03-18 11:22:19 +01:00
Alexander Grund
5c46488d7a Add more status messages to test_iostream
Help to debug random timeouts on Appveyor
2022-03-09 18:55:33 +01:00
Alexander Grund
e82c2aced2 Use std::cout for test status data 2022-03-09 10:49:05 +01:00
Alexander Grund
8d259f16b3 Enhance CTRL+Z iostream test
Output random seed and progress indicator to be able to reproduce failures
2022-03-08 22:13:03 +01:00
Alexander Grund
2ad06c2968 Merge pull request #148 from Flamefire/gcc11_ming-w64-compat
Improve compatibility for recent MinGW-w64 and Cygwin compilers
2022-03-07 12:10:22 +01:00
Alexander Grund
c675e5eb47 Add size-check to the stat_t-using stat function
Same as for the posix_stat_t:
  Ensure that the definitions of that struct hasn't changed between compiling and using the library.
2022-03-06 18:06:13 +01:00
Alexander Grund
365013b9fd Add missing include: shellapi.h
CommandLineToArgvW is defined in shellapi.h not windows.h although the former is usually included by the latter unless e.g. WIN32_LEAN_AND_MEAN is defined.
2022-03-06 12:38:11 +01:00
Alexander Grund
b54d1c24b9 Protect test code against min/max macros 2022-03-06 12:38:10 +01:00
Alexander Grund
df2ca9eee5 Add test defining BOOST_USE_WINDOWS_H
Also add test of this in combination with WIN32_LEAN_AND_MEAN.

Checks for missing includes, such as shellapi.h
2022-03-06 12:37:02 +01:00
Alexander Grund
3178dc17ff Fixup coverity comments
They seemingly need to be above the line they refer to
2021-12-20 14:21:05 +01:00
Alexander Grund
924864a694 Exclude some more lines on Windows 2021-12-15 21:41:34 +01:00
Alexander Grund
c5f43cfecf Fix failure on newer Appveyor images
To read the console output it seems to be required to set the console buffer as active
2021-12-14 16:21:59 +01:00