-
-
Notifications
You must be signed in to change notification settings - Fork 3.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Declare Support for Python 3.12 (#6434)
- Loading branch information
Showing
10 changed files
with
56 additions
and
45 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
3.11 | ||
3.12 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,7 +48,11 @@ async def test_last_exception_and_running(monkeypatch): | |
manager = MagicMock() | ||
err = ValueError("something else") | ||
|
||
async def _raise(*_): | ||
def _raise(*_): | ||
nonlocal err | ||
raise err | ||
|
||
async def _raise_async(*_): | ||
nonlocal err | ||
raise err | ||
|
||
|
@@ -57,12 +61,12 @@ async def _raise(*_): | |
await inst1.start() | ||
assert inst1.last_exception is None | ||
assert inst1.is_running | ||
monkeypatch.setattr(inst1._servers[0], "wait_closed", _raise) | ||
monkeypatch.setattr(inst1._servers[0], "close", _raise) | ||
with pytest.raises(type(err), match=str(err)): | ||
await inst1.stop() | ||
assert inst1.last_exception is err | ||
|
||
monkeypatch.setattr(asyncio, "start_server", _raise) | ||
monkeypatch.setattr(asyncio, "start_server", _raise_async) | ||
inst2 = ServerInstance.make("[email protected]:0", manager) | ||
assert inst2.last_exception is None | ||
with pytest.raises(type(err), match=str(err)): | ||
|