-
Notifications
You must be signed in to change notification settings - Fork 394
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
15 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import pytest | ||
from fixtures.neon_fixtures import NeonEnvBuilder | ||
|
||
|
||
def test_boom(neon_env_builder: NeonEnvBuilder): | ||
""" | ||
Test that calling `SELECT 💣();` (from neon_test_utils) crashes the endpoint | ||
""" | ||
env = neon_env_builder.init_start() | ||
env.neon_cli.create_branch("test_💣") | ||
endpoint = env.endpoints.create_start("test_💣") | ||
|
||
endpoint.safe_psql("CREATE EXTENSION neon_test_utils;") | ||
with pytest.raises(Exception, match="This probably means the server terminated abnormally"): | ||
endpoint.safe_psql("SELECT 💣();") |