Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-111744: Makebreakpoint() enter the debugger immediately#118579

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
brandtbucher merged 6 commits intopython:mainfromgaogaotiantian:pdb-breakpoint
May 5, 2024
Merged
Changes from1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
PrevPrevious commit
NextNext commit
Fix doctest
  • Loading branch information
@gaogaotiantian
gaogaotiantian committedMay 4, 2024
commita1fc073b81dbee768c92945768048bec001799c1
14 changes: 10 additions & 4 deletionsLib/test/test_doctest/test_doctest.py
View file
Open in desktop
Original file line numberDiff line numberDiff line change
Expand Up@@ -2056,8 +2056,7 @@ def test_pdb_set_trace():

>>> try: runner.run(test)
... finally: sys.stdin = real_stdin
--Return--
> <doctest foo-bar@baz[2]>(1)<module>()->None
> <doctest foo-bar@baz[2]>(1)<module>()
-> import pdb; pdb.set_trace()
(Pdb) print(x)
42
Expand DownExpand Up@@ -2087,8 +2086,7 @@ def test_pdb_set_trace():
... runner.run(test)
... finally:
... sys.stdin = real_stdin
--Return--
> <doctest test.test_doctest.test_doctest.test_pdb_set_trace[9]>(3)calls_set_trace()->None
> <doctest test.test_doctest.test_doctest.test_pdb_set_trace[9]>(3)calls_set_trace()
-> import pdb; pdb.set_trace()
(Pdb) print(y)
2
Expand All@@ -2114,6 +2112,7 @@ def test_pdb_set_trace():
>>> test = parser.get_doctest(doc, globals(), "foo-bar@baz", "foo-bar@baz.py", 0)
>>> real_stdin = sys.stdin
>>> sys.stdin = FakeInput([
... 'step', # return event of g
... 'list', # list source from example 2
... 'next', # return from g()
... 'list', # list source from example 1
Expand All@@ -2124,6 +2123,9 @@ def test_pdb_set_trace():
>>> try: runner.run(test)
... finally: sys.stdin = real_stdin
... # doctest: +NORMALIZE_WHITESPACE
> <doctest foo-bar@baz[1]>(3)g()
-> import pdb; pdb.set_trace()
(Pdb) step
--Return--
> <doctest foo-bar@baz[1]>(3)g()->None
-> import pdb; pdb.set_trace()
Expand DownExpand Up@@ -2188,6 +2190,7 @@ def test_pdb_set_trace_nested():
>>> test = parser.get_doctest(doc, globals(), "foo-bar@baz", "foo-bar@baz.py", 0)
>>> real_stdin = sys.stdin
>>> sys.stdin = FakeInput([
... 'step',
... 'print(y)', # print data defined in the function
... 'step', 'step', 'step', 'step', 'step', 'step', 'print(z)',
... 'up', 'print(x)',
Expand All@@ -2201,6 +2204,9 @@ def test_pdb_set_trace_nested():
... finally:
... sys.stdin = real_stdin
... # doctest: +REPORT_NDIFF
> <doctest test.test_doctest.test_doctest.test_pdb_set_trace_nested[0]>(4)calls_set_trace()
-> import pdb; pdb.set_trace()
(Pdb) step
> <doctest test.test_doctest.test_doctest.test_pdb_set_trace_nested[0]>(5)calls_set_trace()
-> self.f1()
(Pdb) print(y)
Expand Down

[8]ページ先頭

©2009-2025 Movatter.jp