diff --git a/test_runner/batch_others/test_gc_aggressive.py b/test_runner/batch_others/test_gc_aggressive.py index 9de6ba9f59..e4e4aa9f4a 100644 --- a/test_runner/batch_others/test_gc_aggressive.py +++ b/test_runner/batch_others/test_gc_aggressive.py @@ -1,10 +1,7 @@ -from contextlib import closing - import asyncio -import asyncpg import random -from fixtures.zenith_fixtures import ZenithEnv, Postgres, Safekeeper +from fixtures.zenith_fixtures import ZenithEnv, Postgres from fixtures.log_helper import log # Test configuration @@ -76,5 +73,5 @@ def test_gc_aggressive(zenith_simple_env: ZenithEnv): asyncio.run(update_and_gc(env, pg, timeline)) - row = cur.execute('SELECT COUNT(*), SUM(counter) FROM foo') + cur.execute('SELECT COUNT(*), SUM(counter) FROM foo') assert cur.fetchone() == (num_rows, updates_to_perform) diff --git a/test_runner/batch_others/test_next_xid.py b/test_runner/batch_others/test_next_xid.py index fd0f761409..03c27bcd70 100644 --- a/test_runner/batch_others/test_next_xid.py +++ b/test_runner/batch_others/test_next_xid.py @@ -1,9 +1,6 @@ -import pytest -import random import time from fixtures.zenith_fixtures import ZenithEnvBuilder -from fixtures.log_helper import log # Test restarting page server, while safekeeper and compute node keep diff --git a/test_runner/batch_others/test_old_request_lsn.py b/test_runner/batch_others/test_old_request_lsn.py index d09fb24913..e7400cff96 100644 --- a/test_runner/batch_others/test_old_request_lsn.py +++ b/test_runner/batch_others/test_old_request_lsn.py @@ -1,5 +1,3 @@ -from contextlib import closing - from fixtures.zenith_fixtures import ZenithEnv from fixtures.log_helper import log diff --git a/test_runner/batch_others/test_pageserver_api.py b/test_runner/batch_others/test_pageserver_api.py index 965ba9bcc3..13f6ef358e 100644 --- a/test_runner/batch_others/test_pageserver_api.py +++ b/test_runner/batch_others/test_pageserver_api.py @@ -1,6 +1,6 @@ from uuid import uuid4, UUID import pytest -from fixtures.zenith_fixtures import ZenithEnv, ZenithEnvBuilder, ZenithPageserverHttpClient, zenith_binpath +from fixtures.zenith_fixtures import ZenithEnv, ZenithEnvBuilder, ZenithPageserverHttpClient # test that we cannot override node id diff --git a/test_runner/batch_others/test_pageserver_catchup.py b/test_runner/batch_others/test_pageserver_catchup.py index 7093a1bdb3..3c4b7f9569 100644 --- a/test_runner/batch_others/test_pageserver_catchup.py +++ b/test_runner/batch_others/test_pageserver_catchup.py @@ -1,11 +1,4 @@ -import pytest -import random -import time - -from contextlib import closing -from multiprocessing import Process, Value from fixtures.zenith_fixtures import ZenithEnvBuilder -from fixtures.log_helper import log # Test safekeeper sync and pageserver catch up diff --git a/test_runner/batch_others/test_pageserver_restart.py b/test_runner/batch_others/test_pageserver_restart.py index 57f9db8f96..20e6f4467e 100644 --- a/test_runner/batch_others/test_pageserver_restart.py +++ b/test_runner/batch_others/test_pageserver_restart.py @@ -1,9 +1,3 @@ -import pytest -import random -import time - -from contextlib import closing -from multiprocessing import Process, Value from fixtures.zenith_fixtures import ZenithEnvBuilder from fixtures.log_helper import log diff --git a/test_runner/batch_others/test_remote_storage.py b/test_runner/batch_others/test_remote_storage.py index 07a122ede9..e762f8589a 100644 --- a/test_runner/batch_others/test_remote_storage.py +++ b/test_runner/batch_others/test_remote_storage.py @@ -1,7 +1,7 @@ # It's possible to run any regular test with the local fs remote storage via # env ZENITH_PAGESERVER_OVERRIDES="remote_storage={local_path='/tmp/zenith_zzz/'}" poetry ...... -import time, shutil, os +import shutil, os from contextlib import closing from pathlib import Path from uuid import UUID diff --git a/test_runner/batch_others/test_snapfiles_gc.py b/test_runner/batch_others/test_snapfiles_gc.py index c6d4512bc9..d00af53864 100644 --- a/test_runner/batch_others/test_snapfiles_gc.py +++ b/test_runner/batch_others/test_snapfiles_gc.py @@ -1,6 +1,5 @@ from contextlib import closing import psycopg2.extras -import time from fixtures.utils import print_gc_result from fixtures.zenith_fixtures import ZenithEnv from fixtures.log_helper import log diff --git a/test_runner/batch_others/test_timeline_size.py b/test_runner/batch_others/test_timeline_size.py index 0b341746ee..db33493d61 100644 --- a/test_runner/batch_others/test_timeline_size.py +++ b/test_runner/batch_others/test_timeline_size.py @@ -1,5 +1,4 @@ from contextlib import closing -from uuid import UUID import psycopg2.extras import psycopg2.errors from fixtures.zenith_fixtures import ZenithEnv, ZenithEnvBuilder, Postgres, assert_local diff --git a/test_runner/batch_others/test_zenith_cli.py b/test_runner/batch_others/test_zenith_cli.py index 4a62a1430a..091d9ac8ba 100644 --- a/test_runner/batch_others/test_zenith_cli.py +++ b/test_runner/batch_others/test_zenith_cli.py @@ -1,8 +1,6 @@ -import json import uuid import requests -from psycopg2.extensions import cursor as PgCursor from fixtures.zenith_fixtures import ZenithEnv, ZenithEnvBuilder, ZenithPageserverHttpClient from typing import cast