It wasn't testing functionality. Now it is (on Linux anyways).
(cherry picked from commit 5f3d04fa4e)
Co-authored-by: Gregory P. Smith <greg@krypto.org>
* bpo-33789: test_asyncio: Fix ResourceWarning (GH-7460)
* Close sockets and streams to fix ResourceWarning warnings
* Catch also OSError to hide a traceback on an expected handshake
error
(cherry picked from commit 0eba7c3913)
* bpo-33789, test_asyncio: Hide PendingDeprecationWarning (GH-7461)
Hide PendingDeprecationWarning in test__register_task_3().
(cherry picked from commit 7ed61e9431)
* bpo-32676, test_asyncio: Fix warning in test_error_in_call_soon() (GH-7462)
Fix "<CoroWrapper ...> was never yielded from" warning in
PyTask_PyFuture_Tests.test_error_in_call_soon() of
test_asyncio.test_tasks.
Close manually the coroutine on error.
(cherry picked from commit 9f04f0df6f)
Document that the default value of repeat changed from 3 to 5 in
Python 3.7.
(cherry picked from commit 3ef769fcd3)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
Substract one because listdir() opens internally a file
descriptor to list the content of the /proc/self/fd/ directory.
Add test_support.test_fd_count().
Move also MAXFD code before msvcrt.CrtSetReportMode(), to make sure
that the report mode is always restored on failure.
(cherry picked from commit 492d6424a7)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
Move the floor() call into fbound() to call floor() on a double
rather than an int. The change should enhance the rounding.
Document also (int)double rounding mode.
(cherry picked from commit 45e4efba7f)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
testModeStrings and testTruncateOnWindows were depended on
a file leaked in other tests.
Also improve cleaning up after tests.
(cherry picked from commit c2745d2d05)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
In addition to that, mark SSLTransport as "closed" in its "abort()" method to prevent bogus warnings.
(cherry picked from commit 415bc46a78)
Co-authored-by: Yury Selivanov <yury@magic.io>
With addCleanup() f.close() was executed after tearDown().
(cherry picked from commit 6592d7fe11)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
Fix test_warnings.test_module_globals() when python3 is run with
-Werror.
(cherry picked from commit e292b75e3e)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
* Fix AttributeError (not all SSL exceptions have 'errno' attribute)
* Increase default handshake timeout from 10 to 60 seconds
* Make sure start_tls can be cancelled correctly
* Make sure any error in SSLProtocol gets propagated (instead of just being logged)
(cherry picked from commit 9602643120)
Co-authored-by: Yury Selivanov <yury@magic.io>
Previously, the mouse wheel and scrollbar slider moved text by a fixed
number of pixels, resulting in partial lines at the top of the editor
box. The change also applies to the shell and grep output windows,
but not to read-only text views.
(cherry picked from commit d49dbd9acc)
Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
Separate tests leaked files or were depended on files leaked in other tests.
(cherry picked from commit 027f95c736)
Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
This is a simple grammatical fix correcting "...object whose `__self__` attributes is ..." to "...object whose `__self__` attribute is ...".
(cherry picked from commit 00818c8ffd)
Co-authored-by: Zach Mitchell <zmitchell@users.noreply.github.com>
The difference from before is that the settings are now on the
Highlights tab instead of the Extensions tab and only change one theme
at a time instead of all themes. The default for light themes is black
on light gray, as before. The default for the IDLE Dark theme is white
on dark gray, which better fits the dark theme.
When one starts IDLE from a console and loads a custom theme without
definitions for 'context', one will see a warning message on the console.
To stop the warning, go to Options => Configure IDLE => Highlights,
select the custom theme if not selected already, select 'Code Context',
and select foreground and background colors.
(cherry picked from commit de6516264e)
Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
Instead of displaying a fixed number of lines, some blank, Code Context
now displays the variable number of actual context lines. When there
are no context lines, it shows a single blank line to indicate that the
feature is turned on.
The Code Context configuration option is changed from 'numlines'
(default 3) to 'maxlines' (default 15) to avoid possible interference
between user settings for the old and new versions of Code Context.
(cherry picked from commit 29996a1c4e)
Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
Use also support.SOCK_MAX_SIZE, not only support.PIPE_MAX_SIZE, to
get the size for a blocking send into a multiprocessing pipe.
(cherry picked from commit 252f6abe0a)
Co-authored-by: Victor Stinner <vstinner@redhat.com>
Fix a crash in Python initialization when parsing the command line
options.
Fix memcpy() size parameter: previously, we read one wchar_t after
the end of _PyOS_optarg. Moreover, don't copy the trailingg NUL
character: we write it manually anyway.
Thanks Christoph Gohlke for the bug report and the fix!
(cherry picked from commit 58d1683255)
Co-authored-by: Victor Stinner <vstinner@redhat.com>